<?php


use app\http\middleware\AllowOriginMiddleware;
use app\http\middleware\api\AuthTokenMiddleware;
use app\http\middleware\api\BlockerMiddleware;
use app\http\middleware\api\ClientMiddleware;
use app\http\middleware\InstallMiddleware;
use app\http\middleware\StationOpenMiddleware;
use think\facade\Config;
use think\facade\Route;
use think\Response;

/**
 * 用户端路由配置
 */
Route::group('api', function () {

	Route::any('wechat/serve', 'v1.wechat.Wechat/serve');//公众号服务
	Route::any('wechat/miniServe', 'v1.wechat.Wechat/miniServe');//小程序服务
	Route::any('work/serve', 'v1.wechat.Wechat/work');//企业微信服务
	Route::any('pay/notify/:type', 'v1.Pay/notify');//支付回调
	Route::any('city_delivery/notify', 'v1.CityDelivery/notify');//UU、达达回调
	Route::get('get_script', 'v1.PublicController/getScript');//统计代码
	Route::get('get_copyright', 'v1.PublicController/getCopyright');//获取版权
	Route::get('ali_pay', 'v1.order.StoreOrder/aliPay')->name('aliPay');// 支付宝复制链接支付
	Route::any('order_call_back', 'v1.order.StoreOrder/callBack');//商家寄件回调
//
	/**
	 * 登录类
	 */
	Route::group(function () {
		//apple快捷登陆
		Route::post('apple_login', 'v1.Login/appleLogin')->name('appleLogin');//微信APP授权
		//账号密码登录
		Route::post('login', 'v1.Login/login')->name('login');
		// 获取发短信的key
		Route::get('verify_code', 'v1.Login/verifyCode')->name('verifyCode');
		//手机号登录
		Route::post('login/mobile', 'v1.Login/mobile')->name('loginMobile');
		//图片验证码
		Route::get('sms_captcha', 'v1.Login/captcha')->name('captcha');
		//验证码发送
		Route::post('register/verify', 'v1.Login/verify')->name('registerVerify');
		//手机号注册
		Route::post('register', 'v1.Login/register')->name('register');
		//手机号修改密码
		Route::post('register/reset', 'v1.Login/reset')->name('registerReset');
		// 绑定手机号(静默授权 还未有用户信息)
		Route::post('binding', 'v1.Login/binding_phone')->name('bindingPhone');
		//图形验证码
		Route::get('ajcaptcha', 'v1.Login/ajcaptcha')->name('ajcaptcha');
		//图形验证码
		Route::post('ajcheck', 'v1.Login/ajcheck')->name('ajcheck');


	})->middleware(StationOpenMiddleware::class);

	/**
	 * 无需授权接口
	 */
	Route::group(function () {
		Route::get('groom_lists', 'v1.product.StoreProduct/groom_lists')->name('groom_lists');//商品推荐
		Route::get('umengPushMsgs', 'v1.order.StoreOrder/umengPushMsgs')->name('groom_lists');//商品推荐
		Route::get('makeFancyString', 'v1.order.StoreOrder/makeFancyString')->name('makeFancyString');//商品推荐

		Route::get('geoLbscoder', 'v1.PublicController/geoLbscoder')->name('geoLbscoder');//经纬度转位置信息

		Route::get('city', 'v2.PublicController/city')->name('city');//增加省市区

		Route::get('site_config', 'v1.PublicController/getSiteConfig')->name('getSiteConfig');//获取网站配置

		Route::get('navigation/[:template_name]', 'v1.PublicController/getNavigation')->name('getNavigation');//获取底部导航

		Route::get('search/hot_keyword', 'v1.PublicController/hotKeywords')->name('hotKeyword');//热门搜索关键字获取
		Route::get('search/keyword', 'v1.PublicController/searchWords')->name('searchKeyword');//搜索关键字关联

		Route::get('category', 'v1.product.StoreProductCategory/category')->name('category');//商品分类类
		Route::get('get_shop_type', 'v1.product.StoreProductCategory/shop_type')->name('shop_type');//商品分类类
		Route::get('level_category', 'v1.product.StoreProductCategory/levelCategory')->name('levelCategory');//商品同级所以分类
		Route::get('category_version', 'v1.product.StoreProductCategory/getCategoryVersion')->name('getCategoryVersion');//商品分类类版本
		Route::get('reply/list/:id', 'v1.product.StoreProductReply/reply_list')->name('replyList');//商品评价列表
		Route::get('reply/config/:id', 'v1.product.StoreProductReply/reply_config')->name('replyConfig');//商品评价数量和好评度


		Route::get('user_agreement/[:type]', 'v1.PublicController/getUserAgreement')->name('getUserAgreement')->middleware(AuthTokenMiddleware::class, false);//获取用户协议
        Route::get('agreement/[:type]', 'v1.PublicController/getAgreement')->name('getUserAgreement')->middleware(AuthTokenMiddleware::class, false);//分销说明

        Route::get('get_open_adv', 'v1.PublicController/getOpenAdv')->name('getOpenAdv');//首页开屏广告
		Route::get('address/user_ship_address', 'v1.user.UserAddress/user_ship_address')->name('user_ship_address');//地址列表

		Route::get('checkUpdateVersion', 'v1.recovery.RecoveryPlate/checkUpdateVersion')->name('checkUpdateVersion');  //关于我们 - 检查更新
		Route::get('getAboutInfo', 'v1.recovery.RecoveryPlate/getAboutInfo')->name('getAboutInfo');  //关于我们 - 获取详情
		Route::post('umengPushMsg', 'v1.recovery.RecoveryPlate/umengPushMsg')->name('umengPushMsg');  //友盟系统推送

		Route::get('code_sms', 'v1.recovery.RecoveryPlate/code_sms')->name('code_sms');
	})->middleware(StationOpenMiddleware::class);
	
	
	
	/**
     * 求职招聘、闲置发布
     * api - 无需授权接口
     */
    Route::group(function () {
        Route::get('getConfigImage', 'v1.recovery.RecoveryProduct/getConfigImage')->name('getConfigImage');  //首页 - top区域 -获取轮播图
        Route::get('getConfigPageImg', 'v1.recovery.RecoveryProduct/getConfigPageImg')->name('getConfigPageImg');  //首页 - 推荐位图


        Route::get('getConfigServData', 'v1.recovery.RecoveryProduct/getConfigServData')->name('getConfigServData');  //个人中心 - 服务列表
        Route::get('getConfigManageData', 'v1.recovery.RecoveryProduct/getConfigManageData')->name('getConfigManageData');  //个人中心 - 管理列表
        Route::get('getAppImgOrigin', 'v1.recovery.RecoveryProduct/getAppImgOrigin')->name('getAppImgOrigin');  //获取静态文件显示的origin

        Route::get('getIndustryList', 'v1.recruit.RecruitIndustry/industry_list')->name('getIndustryList');  //求职招聘 - 获取行业数据列表
        Route::get('jobpoints_list', 'v1.recruit.RecruitCollection/jobpoints_list')->name('jobpoints_list');  //求职使用积分配置
        Route::get('getJobCateList', 'v1.recruit.RecruitCollection/getJobCateList')->name('getJobCateList');  //查询/1工作经验 /2学历/ 3求职状态/4薪资
        Route::get('getAllArea', 'v1.recruit.RecruitCollection/getAllArea')->name('getAllArea');

        Route::get('job_Company_list', 'v1.recruit.RecruitCollection/job_Company_list')->name('job_Company_list');  //查询企业下的职位
        Route::get('getRecruitFirmType', 'v1.recruit.RecruitCollection/getRecruitFirmType')->name('getRecruitFirmType');  //获取企业类型列表

        Route::get('getListLikeData', 'v1.recovery.RecoveryPlate/getListLikeData')->name('getListLikeData');  //闲置-模糊搜索
        Route::get('getProductLikeData', 'v1.recovery.RecoveryPlate/getProductLikeData')->name('getProductLikeData');  //超市-模糊搜索
        Route::get('getCategory', 'v1.recovery.RecoveryPlate/getCategory')->name('getCategory');  //首页 - 获取中部区域 - 分类列表


        Route::get('getPeripProductList', 'v1.recovery.RecoveryPlate/getPeripProductList')->name('getPeripProductList');  //首页 - 闲置好物商品列表
        Route::get('getCardProductList', 'v1.recovery.RecoveryPlate/getCardProductList')->name('getCardProductList');  //首页 - 卡类商品列表
        Route::get('getFreeMarkList', 'v1.recovery.RecoveryPlate/getFreeMarkList')->name('getFreeMarkList');  //首页 - 自由市场商品列表
        Route::get('getFreeIdleList', 'v1.recovery.RecoveryPlate/getFreeIdleList')->name('getFreeIdleList');  //首页 - 店铺闲置商品列表

        Route::get('getCategoryShopList', 'v1.recovery.RecoveryPlate/getCategoryShopList')->name('getCategoryShopList');  //首页 - 根据店铺闲置分类 - 获取店铺列表
        Route::get('getProductShopDetail', 'v1.recovery.RecoveryPlate/getProductShopDetail')->name('getProductShopDetail');  //首页 - 店铺闲置 - 店铺详情
        Route::get('getUserShopDetail', 'v1.recovery.RecoveryProduct/getUserShopDetail')->name('getUserShopDetail');  //个人商家主页详情
        Route::get('getCateProductList', 'v1.recovery.RecoveryProduct/getCateProductList')->name('getCateProductList');  //首页 - 商品列表

        Route::get('getRecoveryShopList', 'v1.recovery.RecoveryProduct/getRecoveryShopList')->name('getRecoveryShopList');  //获取回收/搬家入驻列表

        Route::post('oneclick_login', 'v1.recovery.RecoveryPlate/oneclick_login')->name('oneclick_login');  //智能认证 - 一键登录
        Route::post('phone_verify', 'v1.recovery.RecoveryPlate/phone_verify')->name('phone_verify');  //智能认证 - 本机号码认证
        Route::get('getFeedbackItemType', 'v1.recovery.RecoveryPlate/getFeedbackItemType')->name('getFeedbackItemType');  //个人中心 - 宝贝详情页面 - 交易须知


        Route::get('job_list', 'v1.recruit.RecruitCollection/job_list')->name('job_list');  //获取招聘列表

	    Route::get('systemShareLink', 'v1.recovery.RecoveryProduct/systemShareLink')->name('systemShareLink');  //获取分享链接url - 商品详情
	    Route::get('getSeekerDetail', 'v1.recruit.RecruitCollection/detail')->name('getSeekerDetail');  //求职招聘 -获取个人简历

        Route::group(function () {
	        Route::get('getjob', 'v1.recruit.RecruitCollection/getjob')->name('getjob');  //获取招聘详情

	        Route::get('getTopSearchList', 'v1.recovery.RecoveryPlate/getTopSearchList')->name('getTopSearchList');  //首页 - top区域 - 搜索
            Route::get('getRecruitSearchList', 'v1.recruit.RecruitCollection/getRecruitSearchList')->name('getRecruitSearchList');  //求职招聘 - top区域搜索
            Route::get('getProductDetail', 'v1.recovery.RecoveryProduct/getProductDetail')->name('getProductDetail');  //首页 - 搜索 - 商品详情

            Route::post('createSeeker', 'v1.recruit.RecruitCollection/create')->name('createSeeker');  //求职招聘 - 创建求职 - 个人简历
            Route::post('up_seeker_status', 'v1.recruit.RecruitCollection/up_seeker_status')->name('up_seeker_status');  //个人简历上下架
            Route::post('up_job_status', 'v1.recruit.RecruitCollection/up_job_status')->name('up_job_status');  //在线简历上下架
            Route::post('del_Collection', 'v1.recruit.RecruitCollection/del_Collection')->name('del_Collection');  //取消收藏

            Route::get('jobseeker_list', 'v1.recruit.RecruitCollection/jobseeker_list')->name('jobseeker_list');  //获取求职列表

            Route::get('getUserShareInviteList', 'v1.recovery.RecoveryPlate/getUserShareInviteList')->name('getUserShareInviteList');  //用户邀请记录列表

            Route::get('resumelist', 'v1.recruit.RecruitCollection/resumelist')->name('resumelist');  //附件简历列表
            Route::get('getVipMainDay', 'v1.recovery.RecoveryPlate/getVipMainDay')->name('getVipMainDay');  //获取用户VIP剩余天数

            Route::post('Collection_type2', 'v1.recruit.RecruitCollection/Collection_type2')->name('Collection_type2');  //收藏列表岗位
            Route::post('updateSeeker/:id', 'v1.recruit.RecruitCollection/update')->name('updateSeeker');  //求职招聘 - 修改个人简历
            Route::get('getSeekerPersonDetail', 'v1.recruit.RecruitCollection/getSeekerPersonDetail')->name('getSeekerPersonDetail');  //求职招聘 - 我的 - 获取个人简历
            Route::post('createResume', 'v1.recruit.RecruitCollection/createResume')->name('createResume');  //创建上传简历
            Route::post('deleteResume', 'v1.recruit.RecruitCollection/deleteResume')->name('deleteResume');  //删除附件简历

            Route::get('getPhoneChatCount', 'v1.recruit.RecruitCollection/getPhoneChatCount')->name('getPhoneChatCount');  //获取打电话次数/联系次数
            Route::get('setPhoneChatCount', 'v1.recruit.RecruitCollection/setPhoneChatCount')->name('setPhoneChatCount');  //编辑打电话次数/联系次数
            Route::post('update_company_introduction', 'v1.recruit.RecruitCollection/update_company_introduction')->name('update_company_introduction');  //修改企业介绍
            Route::get('Collection_type1', 'v1.recruit.RecruitCollection/Collection_type1')->name('Collection_type1');  //收藏列表岗位1

            Route::post('authentication_create', 'v1.recruit.RecruitPersonAuthent/authentication_create')->name('authentication_create');  //个人认证创建
            Route::post('authentication_update/:id', 'v1.recruit.RecruitPersonAuthent/authentication_update')->name('authentication_update');  //编辑个人认证
            Route::get('authentication_detail/:id', 'v1.recruit.RecruitPersonAuthent/authentication_detail')->name('authentication_detail');  //获取个人认证详情

            Route::post('createLanguage', 'v1.recruit.RecruitLanguage/createLanguage')->name('createLanguage');  //个人中心 - 添加常用语
            Route::post('getLanguageList', 'v1.recruit.RecruitLanguage/getLanguageList')->name('getLanguageList');  //个人中心 - 获取常用语列表
            Route::post('updateLanguage', 'v1.recruit.RecruitLanguage/updateLanguage')->name('updateLanguage');  //个人中心 - 编辑常用语

            Route::post('create_company', 'v1.recruit.RecruitCollection/create_company')->name('create_company');  //创建企业认证
            Route::post('update_company', 'v1.recruit.RecruitCollection/update_company')->name('update_company');  //编辑企业认证
            Route::get('getCompany', 'v1.recruit.RecruitCollection/getCompany')->name('getCompany');  //获取企业认证详情
            Route::get('getCompanyList', 'v1.recruit.RecruitCollection/getCompanyList')->name('getCompanyList');  //获取企业认证列表
            Route::post('update_company_acquiesce', 'v1.recruit.RecruitCollection/update_company_acquiesce')->name('update_company_acquiesce');  //切换企业
            Route::post('update_acquiesce', 'v1.recruit.RecruitCollection/update_acquiesce')->name('update_acquiesce');  //切换身份

            Route::post('createJob', 'v1.recruit.RecruitCollection/createJob')->name('createJob');  //新建岗位
            Route::post('deleteCompany', 'v1.recruit.RecruitCollection/deleteCompany')->name('deleteCompany');  //删除企业

            Route::post('createCollection', 'v1.recruit.RecruitCollection/createCollection')->name('createCollection');  //收藏求职者添加
            Route::get('getCollectionList', 'v1.recruit.RecruitCollection/getCollectionList')->name('getCollectionList');  //我收藏的 - 求职者列表


            Route::post('deleteSearch', 'v1.recovery.RecoveryProduct/deleteSearch')->name('deleteSearch');  //用户历史搜索删除
            Route::get('searchHistory', 'v1.recovery.RecoveryProduct/searchHistory')->name('searchHistory');  //首页 - 搜索 - 获取用户历史搜索

            Route::get('systemShareGiftLink', 'v1.recovery.RecoveryProduct/systemShareGiftLink')->name('systemShareGiftLink');  //获取分享链接url - 我的礼品卡详情
            Route::get('systemShareRegisterLink', 'v1.recovery.RecoveryProduct/systemShareRegisterLink')->name('systemShareRegisterLink');  //获取分享链接url - 分享邀请新用户注册

            Route::post('getConfigActivityToken', 'v1.recovery.RecoveryPlate/getConfigActivityToken')->name('getConfigActivityToken');  //获取活动配置

            Route::post('createSuggestion', 'v1.recruit.RecruitCollection/createSuggestion')->name('createSuggestion');  //用户建议

        })->middleware(AuthTokenMiddleware::class, true);

        Route::post('getConfigActivity', 'v1.recovery.RecoveryPlate/getConfigActivity')->name('getConfigActivity');  //获取活动配置


        Route::group(function () {
            Route::post('publish', 'v1.recovery.RecoveryProduct/publish')->name('publish');  //首页 - 闲置发布 - 单品发布
            Route::post('publishCard', 'v1.recovery.RecoveryProduct/publishCard')->name('publishCard');  //首页 - 闲置发布 - 单品发布卡类转让
            Route::post('updatePublishCard', 'v1.recovery.RecoveryProduct/updatePublishCard')->name('updatePublishCard');  //我的发布 - 卡类转让 - 商品编辑
            Route::post('publishShop', 'v1.recovery.RecoveryProduct/publishShop')->name('publishShop');  //首页 - 闲置发布 - 发布店铺
            Route::get('getUserShop', 'v1.recovery.RecoveryPlate/getUserShop')->name('getUserShop');  //获取用户店铺
            Route::get('getUserShopNot', 'v1.recovery.RecoveryPlate/getUserShopNot')->name('getUserShopNot');  //获取用户店铺

            Route::get('getIndustryConfigList', 'v1.recovery.RecoveryProduct/getIndustryConfigList')->name('getIndustryConfigList');  //首页 - 发布店铺/办公转租 - 获取行业数据类型列表
            Route::get('getUserShopInfo', 'v1.recovery.RecoveryPlate/getUserShopInfo')->name('getUserShopInfo');  //获取用户最新店铺信息

            Route::post('createRecoveryShopType', 'v1.recovery.RecoveryPlate/createRecoveryShopType')->name('createRecoveryShopType');  //个人中心 - 新增回收/搬家入驻类型
            Route::post('createReport', 'v1.recovery.RecoveryProduct/createReport')->name('createReport');  //用户举报
            Route::get('getMySaleDetail', 'v1.recovery.RecoveryPlate/getMySaleDetail')->name('getMySaleDetail');  //我卖出的 - 待取货详情
            Route::get('getMySaleList', 'v1.recovery.RecoveryPlate/getMySaleList')->name('getMySaleList');  //我卖出的 - 全部商品列表
            Route::post('enableQuote', 'v1.recovery.RecoveryPlate/enableQuote')->name('enableQuote');  //我卖出的 - 列表同意按钮

            Route::get('getListCount', 'v1.recovery.RecoveryPlate/getListCount')->name('getListCount');  //个人中心 - 获取数量
            ////Route::post('regAuthentication', 'v1.recovery.RecoveryPlate/regAuthentication')->name('regAuthentication');  //实名认证提交
            Route::post('createRecovery', 'v1.recovery.RecoveryPlate/createRecovery')->name('createRecovery');  //回收/搬家入驻
            Route::get('collectList', 'v1.recovery.RecoveryPlate/collectList')->name('collectList');  //个人中心 - 我的收藏商品列表

            Route::post('collectCancel', 'v1.recovery.RecoveryProduct/collectCancel')->name('collectCancel');  //我的收藏 - 批量删除收藏
            Route::get('getMyPublishList', 'v1.recovery.RecoveryPlate/getMyPublishList')->name('getMyPublishList');  //我发布的 - 全部商品
            Route::post('updatePublish', 'v1.recovery.RecoveryPlate/updatePublish')->name('updatePublish');  //我的发布 - 商品编辑
            Route::post('enablePublish', 'v1.recovery.RecoveryPlate/enablePublish')->name('enablePublish');  //我的发布 - 商品上下架
            Route::post('enablePublishShop', 'v1.recovery.RecoveryPlate/enablePublishShop')->name('enablePublishShop');  //我的发布 - 店铺上下架


            Route::get('getBuyList', 'v1.recovery.RecoveryPlate/getBuyList')->name('getBuyList');  //我买到的 - 全部商品列表
            Route::post('enableBuyQuote', 'v1.recovery.RecoveryPlate/enableBuyQuote')->name('enableBuyQuote');  //我买到的 - 确认收货
            Route::get('getFeedBackData', 'v1.recovery.RecoveryPlate/getFeedBackData')->name('getFeedBackData');  //个人中心 - 常见问题 - 获取分类类型
            Route::get('getQuestionCate', 'v1.recovery.RecoveryPlate/getQuestionCate')->name('getQuestionCate');  //个人中心 - 获取问题反馈分类

            Route::post('createQuestion', 'v1.recovery.RecoveryPlate/createQuestion')->name('createQuestion');  //个人中心 - 问题反馈提交
            Route::post('cancelBuyQuote', 'v1.recovery.RecoveryPlate/cancelBuyQuote')->name('cancelBuyQuote');  //我买到的 - 用户取消交易
            Route::post('delBuyQuote', 'v1.recovery.RecoveryPlate/delBuyQuote')->name('delBuyQuote');  //我买到的 - 删除订单
            Route::get('getBuyDetail', 'v1.recovery.RecoveryPlate/getBuyDetail')->name('getBuyDetail');  //我买到的 - 待取货详情

            Route::get('getFeedBackItem', 'v1.recovery.RecoveryPlate/getFeedBackItem')->name('getFeedBackItem');  //个人中心 - 常见问题 - 问题详情页面
            ////Route::get('getRegAuthentDetail', 'v1.recovery.RecoveryProduct/getRegAuthentDetail')->name('getRegAuthentDetail');  //个人中心 - 获取个人实名认证详情
            Route::post('updatePublishShop', 'v1.recovery.RecoveryProduct/updatePublishShop')->name('updatePublishShop');  //个人中心 - 我发布的 - 店铺(办公转租)编辑
            Route::post('collect', 'v1.recovery.RecoveryProduct/collect')->name('collect');  //用户添加收藏
            Route::get('checkIsQuote', 'v1.recovery.RecoveryProduct/checkIsQuote')->name('checkIsQuote');  //校验是否已报价
            Route::post('quote', 'v1.recovery.RecoveryProduct/quote')->name('quote');  //用户报价
            Route::post('delPublish', 'v1.recovery.RecoveryPlate/delPublish')->name('delPublish');  //我的发布 - 商品删除
            Route::post('delPublishShop', 'v1.recovery.RecoveryPlate/delPublishShop')->name('delPublishShop');  //我的发布 - 店铺删除


            Route::post('createService', 'v1.recovery.RecoveryPlate/createService')->name('createService');  //创建客服账号

            Route::post('actNewUserInte', 'v1.recovery.RecoveryPlate/actNewUserInte')->name('actNewUserInte');  //弹框点击领取新用户送积分
            Route::post('actNewUserMember', 'v1.recovery.RecoveryPlate/actNewUserMember')->name('actNewUserMember');  //弹框点击领取新用户送vip
            Route::post('act_goods_id', 'v1.recovery.RecoveryPlate/act_goods_id')->name('act_goods_id');  //点击取消推送商品


        })->middleware(AuthTokenMiddleware::class, true);

    })->middleware(StationOpenMiddleware::class);

	
	
	 /**
     * 礼品卡
     * api - 无需授权接口
     */
    Route::group(function () {
	    Route::get('getGiftCardList', 'v1.recovery.GiftCardCollection/getGiftCardList')->name('getGiftCardList');  //获取礼品卡列表
        Route::get('getCardCateTag', 'v1.recovery.GiftCardCollection/getCardCateTag')->name('getCardCateTag');  //礼品卡标签类型
        Route::get('getCardGround', 'v1.recovery.GiftCardCollection/getCardGround')->name('getCardGround');  //获取祝福语背景图
        Route::get('getblessingwords', 'v1.recovery.GiftCardCollection/get_blessing_words')->name('get_blessing_words');  //获取祝福语

        Route::get('getCardEffect', 'v1.recovery.GiftCardCollection/getCardEffect')->name('getCardEffect');  //获取特效视频

        Route::group(function () {

            Route::get('getGiftCardDetail', 'v1.recovery.GiftCardCollection/getGiftCardDetail')->name('getGiftCardDetail');  //礼品卡详情

            Route::post('createCardShareInfo', 'v1.recovery.GiftCardCollection/createCardShareInfo')->name('createCardShareInfo');  //分享礼品卡-自定义信息
            Route::post('getCardShareInfo', 'v1.recovery.GiftCardCollection/getCardShareInfo')->name('getCardShareInfo');  //分享初始化-获取自定义信息

            Route::post('saveGiftShareInfo', 'v1.recovery.GiftCardCollection/saveGiftShareInfo')->name('saveGiftShareInfo');  //购买礼品卡-保存编辑祝福语
            Route::post('getGiftShareInfo', 'v1.recovery.GiftCardCollection/getGiftShareInfo')->name('getGiftShareInfo');  //获取保存编辑祝福语
            Route::post('associationGiftOrderId', 'v1.recovery.GiftCardCollection/associationGiftOrderId')->name('associationGiftOrderId');  //保存编辑订单id


            Route::post('activeGiftCard', 'v1.recovery.GiftCardCollection/activeGiftCard')->name('activeGiftCard');  //礼品卡激活/领取
            Route::post('customGiftBless', 'v1.recovery.GiftCardCollection/customGiftBless')->name('customGiftBless');  //自定义祝福语
            Route::post('createGiftOrder', 'v1.recovery.GiftCardCollection/createGiftOrder')->name('createGiftOrder');  //创建礼品卡订单
            Route::get('getGiftOrderList', 'v1.recovery.GiftCardCollection/getGiftOrderList')->name('getGiftOrderList');  //全部订单列表

            Route::post('cancelGiftOrder', 'v1.recovery.GiftCardCollection/cancelGiftOrder')->name('cancelGiftOrder');  //取消/删除礼品卡订单
            Route::post('reportCheckNumber', 'v1.recovery.GiftCardCollection/reportCheckNumber')->name('reportCheckNumber');  //礼品卡挂失-校验卡号
            Route::post('checkReportGift', 'v1.recovery.GiftCardCollection/checkReportGift')->name('checkReportGift');  //礼品卡挂失 - 身份校验
            Route::post('reportGiftCard', 'v1.recovery.GiftCardCollection/reportGiftCard')->name('reportGiftCard');  //礼品卡挂失
            Route::get('getGiftCarSys', 'v1.recovery.GiftCardCollection/getGiftCarSys')->name('getGiftCarSys');  //获取相关配置
            Route::get('getGiftReportList', 'v1.recovery.GiftCardCollection/getGiftReportList')->name('getGiftReportList');  //获取挂失记录列表

            Route::post('resetGiftCard', 'v1.recovery.GiftCardCollection/resetGiftCard')->name('resetGiftCard');  //挂失补卡
            Route::post('confirmGiftCard', 'v1.recovery.GiftCardCollection/confirmGiftCard')->name('confirmGiftCard');  //确认收货
            Route::get('getGiftCardData', 'v1.recovery.GiftCardCollection/getGiftCardData')->name('getGiftCardData');  //我的礼品卡列表
            Route::get('getGiftCardRecord', 'v1.recovery.GiftCardCollection/getGiftCardRecord')->name('getGiftCardRecord');  //赠送记录列表

            Route::post('delCardUser', 'v1.recovery.GiftCardCollection/delCardUser')->name('delCardUser');  //我的礼品卡 - 删除
            Route::post('bindCardNumber', 'v1.recovery.GiftCardCollection/bindCardNumber')->name('bindCardNumber');  //激活绑定实体卡
            Route::post('factureCardNumber', 'v1.recovery.GiftCardCollection/factureCardNumber')->name('factureCardNumber');  //制作实体卡


        })->middleware(AuthTokenMiddleware::class, true);
    })->middleware(StationOpenMiddleware::class);
	
	

	/**
	 * 授权不通过,不会抛出异常继续执行
	 */
	Route::group(function () {
		//公共类
		Route::get('address/addes_remarks', 'v1.user.UserAddress/addes_remarks')->name('addes_remarks');//地址列表
		Route::get('index', 'v1.PublicController/index')->name('index');//首页
		Route::get('menu/user', 'v1.PublicController/menu_user')->name('menuUser');//个人中心菜单
        Route::get('menu/date', 'v1.PublicController/menu_user_data')->name('menuUserData');//个人中心数据
		Route::get('get_qrcode/:type/:id', 'v1.other.Qrcode/getQrcode')->name('getQrcode');//获取分销二维码

		//商品类
		Route::get('presale/list', 'v1.product.StoreProduct/presaleList')->name('presaleList');//预售商品列表
		Route::get('search/recommend/:type', 'v1.product.StoreProduct/searchRecommendList')->name('searchRecommendList');//搜索页推荐商品
		Route::get('getRecommendList/:type', 'v1.product.StoreProduct/getRecommendList')->name('getRecommendList');//首页推荐商品列表
		Route::get('search/filter', 'v1.product.StoreProduct/searchFilter')->name('searchFilter');//商品分类活动、标签、品牌筛选参数
		Route::get('brand', 'v1.product.StoreProduct/brand')->name('brand');//品牌列表

		Route::get('getUserGoodsName', 'v1.product.StoreProduct/get_user_goods_name')->name('getUserGoodsName');  //get_user_goods_name
		Route::get('get_city', 'v1.product.StoreProduct/get_city')->name('get_city');  //get_city
		Route::get('get_Province', 'v1.product.StoreProduct/get_Province')->name('get_Province');  //get_Province
		Route::get('get_ktyj_Product', 'v1.product.StoreProduct/get_ktyj_Product')->name('get_ktyj_Product');  //get_Province
			Route::get('get_home_product_list_name', 'v1.product.StoreProduct/get_home_product_list_name')->name('get_home_product_list_name');  //查询首页搜索框商品名称
		//列表
		Route::get('search/filter', 'v1.product.StoreProduct/searchFilter')->name('searchFilter');//商品分类活动、标签、品牌筛选参数
		Route::get('brand', 'v1.product.StoreProduct/brand')->name('brand');//品牌列表

		//商品榜单
		Route::get('product/rank/category', 'v1.product.StoreProductRank/rankCategory')->name('RankCategory');//绑定分类列表
		Route::get('product/rank/:type', 'v1.product.StoreProductRank/rankList')->name('RankList');//榜单商品列表

		Route::post('image_base64', 'v1.PublicController/get_image_base64')->name('getImageBase64');// 获取图片base64
		Route::get('product/detail/recommend/:id','v1.product.StoreProduct/recommend')->name('productRecommend');//商品详情推荐商品
		Route::get('product/detail/activity/:id','v1.product.StoreProduct/activity')->name('productActivity');//商品详情关联活动
		Route::get('product/detail/:id/[:type]', 'v1.product.StoreProduct/detail')->name('detail');//商品详情
		Route::get('product/store/detail/:id', 'v2.product.StoreProduct/getStoreProductInfo')->name('getStoreProductInfo');//用平台商品ID获取门店该商品详情
		Route::get('product/detail_content/:id/', 'v1.product.StoreProduct/detailContent')->name('detailContent');//商品详情内容
		Route::get('groom/list/:type', 'v1.product.StoreProduct/groom_list')->name('groomList');//获取首页推荐不同类型商品的轮播图和商品
		Route::get('products', 'v1.product.StoreProduct/lst')->name('products');//商品列表
        Route::get('productsMark', 'v1.product.StoreProduct/Marklst')->name('Marklst');//超市搜索 - 商品列表
		Route::get('product/hot', 'v1.product.StoreProduct/product_hot')->name('productHot');//为你推荐
		Route::get('reply/comment/:id', 'v1.product.StoreProductReply/commentList')->name('commentList');//评价回复列表

		//文章分类类
		Route::get('article/category/list', 'v1.publics.ArticleCategory/lst')->name('articleCategoryList');//文章分类列表
		//文章类
		Route::get('article/list/:cid', 'v1.publics.Article/lst')->name('articleList');//文章列表
		Route::get('article/like/:id', 'v1.publics.Article/userArticleLikes')->middleware(BlockerMiddleware::class)->name('userArticleLikes');//文章点赞
		Route::get('article/details/:id', 'v1.publics.Article/details')->name('articleDetails');//文章详情
		Route::get('article/hot/list', 'v1.publics.Article/hot')->name('articleHotList');//文章 热门
		Route::get('article/new/list', 'v1.publics.Article/new')->name('articleNewList');//文章 最新
		Route::get('article/banner/list', 'v1.publics.Article/banner')->name('articleBannerList');//文章 banner
		//活动---秒杀
		Route::get('seckill/index', 'v1.activity.StoreSeckill/index')->name('seckillIndex');//秒杀商品时间区间
		Route::get('seckill/list/:time', 'v1.activity.StoreSeckill/lst')->name('seckillList');//秒杀商品列表
		Route::get('seckill/detail/:id/[:time]', 'v1.activity.StoreSeckill/detail')->name('seckillDetail');//秒杀商品详情
		Route::get('seckill/detail_code/:id', 'v1.activity.StoreSeckill/detailCode')->name('seckilldetailCode');//秒杀商品二维码
		//活动---砍价
		Route::get('bargain/config', 'v1.activity.StoreBargain/config')->name('bargainConfig');//砍价商品列表配置
		Route::get('bargain/list', 'v1.activity.StoreBargain/lst')->name('bargainList');//砍价商品列表
		Route::get('bargain/detail/:id', 'v1.activity.StoreBargain/detail')->name('bargainDetail');//砍价商品详情
		//活动---拼团
		Route::get('combination/list', 'v1.activity.StoreCombination/lst')->name('combinationList');//拼团商品列表
		Route::get('combination/detail/:id', 'v1.activity.StoreCombination/detail')->name('combinationDetail');//拼团商品详情
		Route::get('combination/detail_code/:id', 'v1.activity.StoreCombination/detailCode')->name('detailCode');//拼团商品详情二维码
		//用户类
		Route::get('user/activity', 'v1.user.User/activity')->name('userActivity');//活动状态

		//微信
		Route::get('wechat/config', 'v1.wechat.Wechat/config')->name('wechatConfig');//微信 sdk 配置
		Route::get('wechat/auth', 'v1.wechat.Wechat/auth')->name('wechatAuth');//微信授权
		Route::post('wechat/app_auth', 'v1.wechat.Wechat/appAuth')->name('appAuth');//微信APP授权

		//小程序登陆
		Route::post('wechat/mp_auth', 'v1.wechat.Routine/mp_auth')->name('mpAuth');//小程序登陆
		Route::get('wechat/get_logo', 'v1.PublicController/getLogo')->name('getLogo');//登陆页面logo
		Route::get('wechat/teml_ids', 'v1.wechat.Routine/teml_ids')->name('wechatTemlIds');//小程序订阅消息
		Route::get('wechat/live', 'v1.wechat.Routine/live')->name('wechatLive');//小程序直播列表
		Route::get('wechat/livePlaybacks/:id', 'v1.wechat.Routine/livePlaybacks')->name('livePlaybacks');//小程序直播回放

		//物流公司
		Route::get('logistics', 'v1.PublicController/logistics')->name('logistics');//物流公司列表

		//分享配置
		Route::get('share', 'v1.PublicController/share')->name('share');//分享配置

		//优惠券
		Route::get('coupons', 'v1.activity.StoreCoupons/lst')->name('couponsList'); //可领取优惠券列表

		//短信购买异步通知
		Route::post('sms/pay/notify', 'v1.PublicController/sms_pay_notify')->name('smsPayNotify'); //短信购买异步通知

		//获取关注微信公众号海报
		Route::get('wechat/follow', 'v1.wechat.Wechat/follow')->name('Follow');
		//用户是否关注
		Route::get('subscribe', 'v1.user.User/subscribe')->name('Subscribe');
		//首页获取用户进入门店（根据进店规则）
		Route::get('get_entry_store', 'v1.store.Store/getUserEntryStore')->name('getUserEntryStore');
		//首页展示门店列表
		Route::get('home/store_list', 'v1.store.Store/getHomeStoreList')->name('homeStoreList');
		//下单选择门店列表
		Route::get('store_list', 'v1.PublicController/store_list')->name('storeList');
		//获取城市列表
		Route::get('city_list', 'v1.PublicController/city_list')->name('cityList');
		//获取附近最近门店
		Route::get('nearby_store', 'v1.store.Store/nearbyStore')->name('nearbyStore');

		Route::get('pink', 'v1.PublicController/pink')->name('pinkData');
		Route::get('combination/banner_list', 'v1.activity.StoreCombination/banner_list')->name('combinationBannerList');//拼团列表轮播图

		Route::post('user/set_visit', 'v1.user.User/set_visit')->name('setVisit');// 添加用户访问记录
		Route::get('copy_words', 'v1.PublicController/copy_words')->name('copyWords');// 复制口令接口

		//活动---积分商城
		Route::get('store_integral/index', 'v1.activity.StoreIntegral/index')->name('storeIntegralIndex');//积分商城首页数据
        Route::get('store_integral/category', 'v1.activity.StoreIntegral/category')->name('storeIntegralCategory');//积分商城分类列表
        Route::get('store_integral/list', 'v1.activity.StoreIntegral/lst')->name('storeIntegralList');//积分商品列表
		Route::get('store_integral/detail/:id', 'v1.activity.StoreIntegral/detail')->name('storeIntegralDetail');//积分商品详情

        Route::get('store_integral/getIntegralCount', 'v1.activity.StoreIntegral/getIntegralCount')->name('getIntegralCount');//ui - 我的积分


		//优惠套餐列表
		Route::get('store_discounts/list/:product_id', 'v1.activity.StoreDiscounts/index');

		//获取客服类型
		Route::get('get_customer_type', 'v2.PublicController/getCustomerType')->name('getCustomerType');//获取客服类型
		Route::get('user/service/get_adv', 'v1.user.StoreService/getKfAdv')->name('userServiceGetKfAdv');//获取客服页面广告

        Route::post('user/spread', 'v1.user.User/spread')->name('userSpread');//静默绑定授权

		//购物车
		Route::get('cart/list', 'v1.order.StoreCart/lst')->name('cartList'); //购物车列表
		Route::get('cart/count', 'v1.order.StoreCart/count')->name('cartCount'); //购物车 获取数量
		Route::get('cart/counts', 'v1.order.StoreCart/counts')->name('cartCount'); //购物车 获取数量

	})->middleware(StationOpenMiddleware::class)->middleware(AuthTokenMiddleware::class, false);

	/**
	 * diy相关
	 */
	Route::group('diy', function () {

		//无需登录接口
		Route::group(function () {
			Route::get('diy_version/[:id]', 'v1.diy.Diy/getDiyVersion');//DIY版本接口
		});

		//未授权接口---不会抛异常
		Route::group(function () {
			Route::get('get_diy/[:id]', 'v1.diy.Diy/getDiy');//DIY接口
			Route::get('user_info', 'v1.diy.Diy/userInfo')->name('diyUserInfo');//diy用户信息
			Route::get('video_list', 'v1.diy.Diy/videoList')->name('diyVideoList');//diy短视频列表
			Route::get('newcomer_list', 'v1.diy.Diy/newcomerList')->name('diyNewcomerList');//diy新人专享商品列表
            Route::get('product_rank', 'v1.diy.Diy/productRank')->name('diyNewcomerList');//diy新人专享商品列表
            Route::get('sign', 'v1.diy.Diy/diySign')->name('diySign');//diy签到数据
            Route::get('get_suspended', 'v1.diy.Diy/getSuspendedDiy')->name('getSuspendedDiy');//diy悬浮窗数据
		})->middleware(AuthTokenMiddleware::class, false);

		//需要授权接口
		Route::group(function () {

		})->middleware(AuthTokenMiddleware::class, true);

	})->middleware(StationOpenMiddleware::class);


	/**
	 * 会员授权接口
	 */
    Route::group(function () {
	    Route::post('delRecord', 'v1.user.User/delRecord')->name('delRecord');//删除
	    //用户修改手机号
	    Route::post('chatmesscout', 'v1.user.User/chatmesscout')->name('chatmesscout');//删除
		//用户修改手机号
		Route::post('user/updatePhone', 'v1.Login/update_binding_phone')->name('updateBindingPhone');
		//设置登录code
		Route::post('user/code', 'v1.user.StoreService/setLoginCode')->name('setLoginCode');
		//查看code是否可用
		Route::get('user/code', 'v1.Login/setLoginKey')->name('getLoginKey');
		//用户绑定手机号
		Route::post('user/binding', 'v1.Login/user_binding_phone')->name('userBindingPhone');
		Route::get('logout', 'v1.Login/logout')->name('logout');// 退出登录
		Route::post('switch_h5', 'v1.Login/switch_h5')->name('switch_h5');// 切换账号

		//商品类
		Route::get('product/code/:id', 'v1.product.StoreProduct/code')->name('productCode');//商品分享二维码 推广员

        //保存商品评价回复
        Route::post('reply/comment/:id', 'v1.product.StoreProductReply/replyComment')->middleware(BlockerMiddleware::class)->name('replyComment');
        //获取评论详情
        Route::get('reply/info/:id', 'v1.product.StoreProductReply/replyInfo')->name('replyInfo');
        //评论回复点赞
        Route::post('reply/praise/:id', 'v1.product.StoreProductReply/commentPraise')->middleware(BlockerMiddleware::class)->name('commentPraise');
        //取消评论回复点赞
        Route::post('reply/un_praise/:id', 'v1.product.StoreProductReply/unCommentPraise')->middleware(BlockerMiddleware::class)->name('unCommentPraise');
        //评论点赞
        Route::post('reply/reply_praise/:id', 'v1.product.StoreProductReply/replyPraise')->middleware(BlockerMiddleware::class)->name('replyPraise');
        //取消评论点赞
        Route::post('reply/un_reply_praise/:id', 'v1.product.StoreProductReply/unReplyPraise')->middleware(BlockerMiddleware::class)->name('unReplyPraise');

        //公共类
        ////Route::post('upload/image', 'v1.PublicController/upload_image')->middleware(BlockerMiddleware::class)->name('uploadImage');//图片上传
	    Route::post('upload/upload_flie', 'v1.PublicController/upload_flie')->middleware(BlockerMiddleware::class)->name('upload_flie');//文件上传
	    Route::post('upload/uploadQiniuImage', 'v1.PublicController/uploadQiniuImage')->middleware(BlockerMiddleware::class)->name('uploadQiniuImage');//图片上传七牛云

        //用户类 客服聊天记录
        Route::get('user/service/list', 'v1.user.StoreService/lst')->name('userServiceList');//客服列表
        Route::get('user/service/record', 'v1.user.StoreService/record')->name('userServiceRecord');//客服聊天记录
        Route::post('user/service/feedback', 'v1.user.StoreService/saveFeedback')->name('saveFeedback');//保存客服反馈信息
        Route::get('user/service/feedback', 'v1.user.StoreService/getFeedbackInfo')->name('getFeedbackInfo');//获得客服反馈头部信息
		Route::get('user/record', 'v1.user.StoreService/recordList')->name('recordList');//获取用户和客服的消息列表

        //用户类  用户
	    Route::get('kt_list', 'v1.user.User/kt_list')->name('kt_list');//获取用户水站配置
	    Route::get('order_kt_list', 'v1.order.StoreOrder/order_kt_list')->name('order_kt_list');//获取用户水站配置
        Route::get('user', 'v1.user.User/user')->name('user');//个人中心
	    Route::get('user_info', 'v1.user.User/user_info')->name('user_info');//user_info

        Route::post('user/edit', 'v1.user.User/edit')->name('userEdit');//用户修改信息
        Route::get('user/balance', 'v1.user.User/balance')->name('userBalance');//用户资金统计
        Route::get('userinfo', 'v1.user.User/userinfo')->name('userinfo');// 用户信息
        Route::get('user/rand_code', 'v1.user.User/randCode')->name('randCode');//查看用户code
        Route::get('user/visit_list', 'v1.user.User/visitList')->name('visitList');//商品浏览列表
        Route::delete('user/visit', 'v1.user.User/visitDelete')->name('visitDelete');//商品浏览记录删除
		Route::get('cancel/user', 'v1.PublicController/cancelUser')->name('cancelUser');// 用户注销


        //用户类  地址
        Route::get('address/detail/:id', 'v1.user.UserAddress/address')->name('address');//获取单个地址
        Route::get('address/list', 'v1.user.UserAddress/address_list')->name('addressList');//地址列表
        Route::post('address/default/set', 'v1.user.UserAddress/address_default_set')->name('addressDefaultSet');//设置默认地址
        Route::get('address/default', 'v1.user.UserAddress/address_default')->name('addressDefault');//获取默认地址
        Route::post('address/edit', 'v1.user.UserAddress/address_edit')->name('addressEdit');//修改 添加 地址
        Route::post('address/del', 'v1.user.UserAddress/address_del')->name('addressDel');//删除地址
        //用户类 收藏
        Route::get('collect/user', 'v1.user.UserCollect/collect_user')->name('collectUser');//收藏商品列表
        Route::post('collect/add', 'v1.user.UserCollect/collect_add')->middleware(BlockerMiddleware::class)->name('collectAdd');//添加收藏
        Route::post('collect/del', 'v1.user.UserCollect/collect_del')->name('collectDel');//取消收藏
        Route::post('collect/all', 'v1.user.UserCollect/collect_all')->name('collectAll');//批量添加收藏

        Route::get('brokerage_rank', 'v1.user.UserBrokerage/brokerage_rank')->name('brokerageRank');//佣金排行
        Route::get('rank', 'v1.user.User/rank')->name('rank');//推广人排行
        //用戶类 分享
        Route::post('user/share', 'v1.PublicController/user_share')->name('user_share');//记录用户分享
        Route::get('user/share/words', 'v1.PublicController/copy_share_words')->name('user_share_words');//关键字分享
        //用户类 点赞
//    Route::post('like/add', 'user.User/like_add')->name('likeAdd');//添加点赞
//    Route::post('like/del', 'user.User/like_del')->name('likeDel');//取消点赞
        //用户类 签到
        Route::get('sign/status', 'v1.user.UserSign/get_sign_status')->name('getSignStatus');//签到配置
        Route::get('sign/config', 'v1.user.UserSign/sign_config')->name('signConfig');//签到配置
        Route::get('sign/list', 'v1.user.UserSign/sign_list')->name('signList');//签到列表
        Route::get('sign/month', 'v1.user.UserSign/sign_month')->name('signIntegral');//签到列表（年月）
        Route::post('sign/user', 'v1.user.UserSign/sign_user')->name('signUser');//签到用户信息
        Route::post('sign/integral', 'v1.user.UserSign/sign_integral')->middleware(BlockerMiddleware::class)->name('signIntegral');//签到
        Route::get('sign/remind/:status', 'v1.user.UserSign/sign_remind')->name('signRemind');//用户设置签到提醒
        Route::get('sign/calendar', 'v1.user.UserSign/sign_calendar')->name('signCalendar');//日历数据

        //优惠券类
        Route::post('coupon/receive', 'v1.activity.StoreCoupons/receive')->middleware(BlockerMiddleware::class)->name('couponReceive'); //领取优惠券
        Route::post('coupon/receive/batch', 'v1.activity.StoreCoupons/receive_batch')->middleware(BlockerMiddleware::class)->name('couponReceiveBatch'); //批量领取优惠券
        Route::get('coupons/user/num', 'v1.activity.StoreCoupons/userCount')->name('userCount');//我的优惠券数量
        Route::get('coupons/user/:types', 'v1.activity.StoreCoupons/user')->name('couponsUser');//用户已领取优惠券
        Route::get('coupons/order/:price', 'v1.activity.StoreCoupons/order')->name('couponsOrder');//优惠券 订单列表


        //购物车类
        Route::post('cart/compute', 'v1.order.StoreCart/computeCart')->name('computeCart'); //购物车列表重新计算
        Route::post('cart/add', 'v1.order.StoreCart/add')->middleware(BlockerMiddleware::class)->name('cartAdd'); //购物车添加
        Route::post('cart/del', 'v1.order.StoreCart/del')->name('cartDel'); //购物车删除
        Route::post('order/cancel', 'v1.order.StoreOrder/cancel')->name('orderCancel'); //订单取消
        Route::post('cart/num', 'v1.order.StoreCart/num')->name('cartNum'); //购物车 修改商品数量

        //订单类
        Route::post('order/check_shipping', 'v1.order.StoreOrder/checkShipping')->name('checkShipping'); //检测是否显示快递和核销标签
        Route::post('order/confirm', 'v1.order.StoreOrder/confirm')->middleware(BlockerMiddleware::class)->name('orderConfirm'); //订单确认
        Route::post('order/computed/:key', 'v1.order.StoreOrder/computedOrder')->middleware(BlockerMiddleware::class)->name('computedOrder'); //计算订单金额
        Route::post('order/create/:key', 'v1.order.StoreOrder/create')->middleware(BlockerMiddleware::class)->name('orderCreate'); //订单创建
	    Route::post('order/water_create', 'v1.order.StoreOrder/water_create')->middleware(BlockerMiddleware::class)->name('water_create'); //一件送水
	    Route::post('order/order_ziyou_heyan', 'store.StoreDelivery/order_ziyou_heyan')->middleware(BlockerMiddleware::class)->name('order_ziyou_heyan'); //审核自由空桶
	    Route::post('order/water_kt_create', 'v1.order.StoreOrder/water_kt_create')->middleware(BlockerMiddleware::class)->name('water_kt_create'); //申请自由空桶
	    Route::post('order/water_user_info', 'v1.order.StoreOrder/water_user_info')->middleware(BlockerMiddleware::class)->name('water_user_info'); //查询水站用户配置
	    Route::post('order/kt_create', 'v1.order.StoreOrder/kt_create')->middleware(BlockerMiddleware::class)->name('kt_create'); //申请自由空桶
	    Route::post('order/water_user_kt_count', 'v1.order.StoreOrder/water_user_kt_count')->middleware(BlockerMiddleware::class)->name('water_user_kt_count');//退空桶   顶部数据
	    Route::post('order/water_user_kt_list', 'v1.order.StoreOrder/water_user_kt_list')->middleware(BlockerMiddleware::class)->name('water_user_kt_list'); //是否自由空桶审核
	    Route::post('order/water_user_kt_tk', 'v1.order.StoreOrder/water_user_kt_tk')->middleware(BlockerMiddleware::class)->name('water_user_kt_tk'); //退空桶列表
	    Route::post('order/is_water_kt_create', 'v1.order.StoreOrder/is_water_kt_create')->middleware(BlockerMiddleware::class)->name('is_water_kt_create'); //判断是否有申请过自由空桶


		Route::get('order/cashier/:orderId/[:type]', 'v1.order.StoreOrder/cashier')->name('orderCashier'); //订单收银台
        Route::get('order/data', 'v1.order.StoreOrder/data')->name('orderData'); //订单统计数据
	    Route::get('order/water_list', 'v1.order.StoreOrder/water_list')->name('water_list'); //水票
	    Route::get('order/water_lists', 'v1.order.StoreOrder/water_lists')->name('water_lists'); //订单列表
        Route::get('order/list', 'v1.order.StoreOrder/lst')->name('orderList'); //订单列表
        Route::get('order/detail/:uni', 'v1.order.StoreOrder/detail')->name('orderDetail'); //订单详情
        Route::get('order/delivery_order_detail/:uni', 'v1.order.StoreOrder/delivery_order_detail')->name('orderDetail'); //订单详情
		Route::post('order/prize/:orderId', 'v1.order.StoreOrder/getOrderPrize');//获取订单下单奖励
        Route::get('order/write/records/:id', 'v1.order.StoreOrder/writeOffRecords')->name('writeOffRecords'); //订单核销记录
        Route::get('delivery_order/detail/:id', 'v1.order.StoreOrder/deliveryOrderDetail')->name('deliveryOrderDetail'); //配送订单详情
        //订单售后
        Route::get('order/refund/reason', 'v1.order.StoreOrder/refund_reason')->name('orderRefundReason'); //订单退款理由
        Route::get('order/refund/cart_info/:id', 'v1.order.StoreOrder/refundCartInfo')->name('StoreOrderRefundCartInfo');//获取退款商品列表
        Route::post('order/refund/cart_info', 'v1.order.StoreOrder/refundCartInfoList')->name('StoreOrderRefundCartInfoList');//获取退款商品列表
        Route::post('order/refund/apply/:id', 'v1.order.StoreOrder/applyRefund')->middleware(BlockerMiddleware::class)->name('StoreOrderApplRefund');//订单申请退款V2
        Route::post('order/refund/verify', 'v1.order.StoreOrder/refund_verify')->middleware(BlockerMiddleware::class)->name('orderRefundVerify'); //订单申请退款
        Route::post('order/refund/express', 'v1.order.StoreOrder/refund_express')->name('orderRefundExpress'); //退货退款填写订单号
        Route::get('order/refund/list', 'v1.order.StoreOrderRefund/lst')->name('orderRefundList'); //售后订单列表
        Route::get('order/refund/detail/:uni', 'v1.order.StoreOrderRefund/detail')->name('orderRefundDetail'); //售后订单详情
        Route::post('order/refund/cancel/:uni', 'v1.order.StoreOrderRefund/cancelApply')->name('orderRefundCancel'); //取消售后申请
		Route::post('order/refund/again/:id', 'v1.order.StoreOrderRefund/againRefundOrder')->middleware(BlockerMiddleware::class)->name('againRefundOrder'); //再次提交售后申请
        Route::get('order/refund/del/:uni', 'v1.order.StoreOrderRefund/delRefundOrder')->middleware(BlockerMiddleware::class)->name('delRefundOrder'); //删除已退款和拒绝退款的订单

        Route::post('order/take', 'v1.order.StoreOrder/take')->middleware(BlockerMiddleware::class)->name('orderTake'); //订单收货
        Route::get('order/express/:uni/[:type]', 'v1.order.StoreOrder/express')->name('orderExpress'); //订单查看物流
        Route::post('order/del', 'v1.order.StoreOrder/del')->name('orderDel'); //订单删除
        Route::post('order/again', 'v1.order.StoreOrder/again')->name('orderAgain'); //订单 再次下单
        Route::post('order/pay', 'v1.order.StoreOrder/pay')->name('orderPay'); //订单支付
        Route::post('order/product', 'v1.order.StoreOrder/product')->name('orderProduct'); //订单商品信息
        Route::post('order/comment', 'v1.order.StoreOrder/comment')->middleware(BlockerMiddleware::class)->name('orderComment'); //订单评价
        Route::get('order/pay_cashier', 'v1.order.StoreOrder/payCashierOrder')->name('payCashierOrder'); //用户门店下单付款
        //活动---砍价
        Route::post('bargain/start', 'v1.activity.StoreBargain/start')->middleware(BlockerMiddleware::class)->name('bargainStart');//砍价开启
        Route::post('bargain/start/user', 'v1.activity.StoreBargain/start_user')->name('bargainStartUser');//砍价 开启砍价用户信息
        Route::post('bargain/share', 'v1.activity.StoreBargain/share')->name('bargainShare');//砍价 观看/分享/参与次数
        Route::post('bargain/help', 'v1.activity.StoreBargain/help')->middleware(BlockerMiddleware::class)->name('bargainHelp');//砍价 帮助好友砍价
        Route::post('bargain/help/price', 'v1.activity.StoreBargain/help_price')->name('bargainHelpPrice');//砍价 砍掉金额
        Route::post('bargain/help/count', 'v1.activity.StoreBargain/help_count')->name('bargainHelpCount');//砍价 砍价帮总人数、剩余金额、进度条、已经砍掉的价格
        Route::post('bargain/help/list', 'v1.activity.StoreBargain/help_list')->name('bargainHelpList');//砍价 砍价帮
        Route::get('bargain/user/list', 'v1.activity.StoreBargain/user_list')->name('bargainUserList');//砍价列表(已参与)
        Route::post('bargain/user/cancel', 'v1.activity.StoreBargain/user_cancel')->name('bargainUserCancel');//砍价取消
        Route::get('bargain/poster_info/:bargainId', 'v1.activity.StoreBargain/posterInfo')->name('posterInfo');//砍价海报详细信息
        //活动---拼团
        Route::get('combination/pink/:id', 'v1.activity.StoreCombination/pink')->name('combinationPink');//拼团开团
        Route::post('combination/remove', 'v1.activity.StoreCombination/remove')->name('combinationRemove');//拼团 取消开团
        Route::get('combination/poster_info/:id', 'v1.activity.StoreCombination/posterInfo')->name('pinkPosterInfo');//拼团海报详细获取
        //账单类
        Route::get('commission', 'v1.user.UserBrokerage/commission')->name('commission');//推广数据 昨天的佣金 累计提现金额 当前佣金
        Route::post('spread/people', 'v1.user.User/spread_people')->name('spreadPeople');//推荐用户
        Route::post('spread/order', 'v1.user.UserBrokerage/spread_order')->name('spreadOrder');//推广订单
        Route::get('spread/commission/:type', 'v1.user.UserBill/spread_commission')->name('spreadCommission');//推广佣金明细
        Route::get('spread/count/:type', 'v1.user.UserBrokerage/spread_count')->name('spreadCount');//推广 佣金 3/提现 4 总和
        Route::get('integral/list', 'v1.user.UserBill/integral_list')->name('integralList');//积分记录
        
        Route::get('integral/share_list', 'v1.user.UserBill/integral_share_list')->name('integral_share_list');//分享记录
        Route::get('integral/list_top', 'v1.user.UserBill/integral_list_top')->name('integralListTop');//积分记录 - 顶部积分明细ui
        
        Route::get('user/routine_code', 'v1.user.UserBill/getRoutineCode')->name('getRoutineCode');//小程序二维码
        Route::get('user/spread_info', 'v1.user.UserBill/getSpreadInfo')->name('getSpreadInfo');//获取分销背景等信息
        //提现类
        Route::get('extract/bank', 'v1.user.UserExtract/bank')->name('extractBank');//提现银行/提现最低金额
        Route::post('extract/cash', 'v1.user.UserExtract/cash')->middleware(BlockerMiddleware::class)->name('extractCash');//提现申请
        //充值类
        Route::post('recharge/recharge', 'v1.user.UserRecharge/recharge')->middleware(BlockerMiddleware::class)->name('rechargeRecharge');//统一充值
		Route::post('recharge/pay', 'v1.user.UserRecharge/pay')->middleware(BlockerMiddleware::class)->name('rechargePay');//统一充值 支付
        Route::get('recharge/index', 'v1.user.UserRecharge/index')->name('rechargeQuota');//充值余额选择
        //会员等级类
        Route::get('user/level/detection', 'v1.user.UserLevel/detection')->name('userLevelDetection');//检测用户是否可以成为会员
        Route::get('user/level/grade', 'v1.user.UserLevel/grade')->name('userLevelGrade');//会员等级列表
        Route::get('user/level/task/:id', 'v1.user.UserLevel/task')->name('userLevelTask');//获取等级任务
        Route::get('user/level/info', 'v1.user.UserLevel/userLevelInfo')->name('levelInfo');//获取等级任务
        Route::get('user/level/expList', 'v1.user.UserLevel/expList')->name('expList');//获取等级任务
        Route::get('user/level/activate_info', 'v1.user.UserLevel/activateInfo')->name('userActivateInfo');//用户激活会员卡需要的信息
        Route::post('user/level/activate', 'v1.user.UserLevel/activateLevel')->name('userActivateLevel');//用户激活会员卡

        //首页获取未支付订单
        Route::get('order/nopay', 'v1.order.StoreOrder/get_noPay')->name('getNoPay');//获取未支付订单

        Route::get('seckill/code/:id', 'v1.activity.StoreSeckill/code')->name('seckillCode');//秒杀商品海报
        Route::get('combination/code/:id', 'v1.activity.StoreCombination/code')->name('combinationCode');//拼团商品海报

        //会员卡
        Route::get('user/member/card/index', 'v1.user.MemberCard/index')->name('userMemberCardIndex');// 主页会员权益介绍页
        Route::post('user/member/card/draw', 'v1.user.MemberCard/draw_member_card')->middleware(BlockerMiddleware::class)->name('userMemberCardDraw');//卡密领取会员卡
        Route::post('user/member/card/create', 'v1.order.OtherOrder/create')->middleware(BlockerMiddleware::class)->name('userMemberCardCreate');//购买卡创建订单
		Route::post('user/member/card/pay', 'v1.order.OtherOrder/pay')->name('userMemberCardCreatePay');//会员订单支付
        Route::get('user/member/coupons/list', 'v1.user.MemberCard/memberCouponList')->name('userMemberCouponsList');//会员券列表
        Route::get('user/member/overdue/time', 'v1.user.MemberCard/getOverdueTime')->name('userMemberOverdueTime');//会员时间
        //线下付款
        Route::post('order/offline/check/price', 'v1.order.OtherOrder/computed_offline_pay_price')->name('orderOfflineCheckPrice'); //检测线下付款金额
        Route::post('order/offline/create', 'v1.order.OtherOrder/create')->name('orderOfflineCreate'); //检测线下付款金额
        Route::post('order/offline/order_get', 'v1.order.OtherOrder/order_get')->name('order_get'); //检测会员订单时候支付
        Route::get('order/offline/pay/type', 'v1.order.OtherOrder/pay_type')->name('orderOfflineCreate'); //线下付款支付方式
        //积分商城订单
        Route::post('store_integral/order/confirm', 'v1.activity.StoreIntegralOrder/confirm')->name('storeIntegralOrderConfirm'); //订单确认
        Route::post('store_integral/order/create', 'v1.activity.StoreIntegralOrder/create')->name('storeIntegralOrderCreate'); //订单创建
        Route::get('store_integral/order/detail/:uni', 'v1.activity.StoreIntegralOrder/detail')->name('storeIntegralOrderDetail'); //订单详情
        Route::get('store_integral/order/list', 'v1.activity.StoreIntegralOrder/lst')->name('storeIntegralOrderList'); //订单列表
        Route::post('store_integral/order/take', 'v1.activity.StoreIntegralOrder/take')->name('storeIntegralOrderTake'); //订单收货
        Route::get('store_integral/order/express/:uni', 'v1.activity.StoreIntegralOrder/express')->name('storeIntegralOrderExpress'); //订单查看物流
        Route::post('store_integral/order/del', 'v1.activity.StoreIntegralOrder/del')->name('storeIntegralOrderDel'); //订单删除
        //消息站内信
		Route::get('user/message', 'v1.user.SystemMessage/message')->name('MessageSystemList'); //用户信息
        Route::get('user/message_system/list', 'v1.user.SystemMessage/message_list')->name('SystemMessageList'); //站内信列表
        Route::get('user/message_system/detail/:id', 'v1.user.SystemMessage/detail')->name('SystemMessageDetail'); //详情
        Route::post('user//sticky', 'v1.user.SystemMessage/sticky')->name('sticky'); //置顶
        Route::post('user/sticky', 'v1.user.SystemMessage/sticky')->name('sticky'); //置顶

		//供应商申请
		Route::get('user/apply/record', 'v1.system.SupplierApply/userApplyRecord')->name('userApplyRecord'); //供应商申请记录
		Route::post('user/apply/supplier/:id', 'v1.system.SupplierApply/userApply')->middleware(BlockerMiddleware::class)->name('userApplySupplier'); //供应商申请
		Route::get('user/apply/:id', 'v1.system.SupplierApply/getInfo')->name('userApplyInfo'); //单个申请记录数据
		//分销员申请
		Route::get('user/promoter/apply/info', 'v1.system.PromoterApply/applyInfo')->name('申请信息');//申请信息
		Route::post('user/promoter/apply/:id', 'v1.system.PromoterApply/applyPromoter')->name('申请分销员');//申请分销员

    })->middleware(StationOpenMiddleware::class)->middleware(AuthTokenMiddleware::class, true);

    /**
     * v1.1 版本路由
     */
    Route::group('v2', function () {
        //无需授权接口
        Route::group(function () {
			//小程序登录页面自动加载，返回用户信息的缓存key，返回是否强制绑定手机号
			Route::get('routine/auth_type', 'v2.wechat.Routine/authType')->option(['real_name' => '小程序页面登录类型']);
			//小程序授权登录，返回token
			Route::get('routine/auth_login', 'v2.wechat.Routine/authLogin')->option(['real_name' => '小程序授权登录']);
			//小程序授权绑定手机号
			Route::post('routine/auth_binding_phone', 'v2.wechat.Routine/authBindingPhone')->option(['real_name' => '小程序授权绑定手机号']);
			//小程序手机号直接登录
			Route::post('routine/phone_login', 'v2.wechat.Routine/phoneLogin')->option(['real_name' => '手机号直接登录']);
			//小程序授权后绑定手机号
			Route::post('routine/binding_phone', 'v2.wechat.Routine/BindingPhone')->option(['real_name' => '小程序授权后绑定手机号']);
			//公众号授权登录，返回token
			Route::get('wechat/auth_login', 'v2.wechat.Wechat/authLogin')->option(['real_name' => '公众号授权登录']);
			//公众号授权绑定手机号
			Route::post('wechat/auth_binding_phone', 'v2.wechat.Wechat/silenceAuthBindingPhone')->option(['real_name' => '公众号授权绑定手机号']);
			Route::get('wechat/getJSSDK', 'v2.wechat.Wechat/getJSSDK');


            //小程序授权
            Route::get('wechat/routine_auth', 'v2.wechat.Routine/auth');
            //小程序静默授权
            Route::get('wechat/silence_auth', 'v2.wechat.Routine/silenceAuthNoLogin');
            //小程序静默授权登陆
            Route::get('wechat/silence_auth_login', 'v2.wechat.Routine/silenceAuth');
			//小程序授权绑定手机号
			Route::post('auth_bindind_phone', 'v2.wechat.Routine/authBindingPhone');
			//小程序手机号登录直接绑定
			Route::post('phone_silence_auth', 'v2.wechat.Routine/silenceAuthBindingPhone');
			//公众号授权登录
			Route::get('wechat/auth', 'v2.wechat.Wechat/auth');
            //公众号静默授权
            Route::get('wechat/wx_silence_auth', 'v2.wechat.Wechat/silenceAuthNoLogin');
            //公众号静默授权登陆
            Route::get('wechat/wx_silence_auth_login', 'v2.wechat.Wechat/silenceAuth');
			//微信手机号登录直接绑定
			Route::post('phone_wx_silence_auth', 'v2.wechat.Wechat/silenceAuthBindingPhone');

            //DIY接口
            Route::get('diy/get_diy/[:name]', 'v2.PublicController/getDiy');
            //是否强制绑定手机号
            Route::get('bind_status', 'v2.PublicController/bindPhoneStatus');
            //获取门店核销开启状态
            Route::get('diy/get_store_status', 'v2.PublicController/getStoreStatus');
            //一键换色
            Route::get('diy/color_change/:name', 'v2.PublicController/colorChange');
			//商品详情diy
            Route::get('diy/product_detail', 'v2.PublicController/productDetailDiy');
            //获取地址列表
            Route::get('cityList', 'v2.PublicController/cityList');
            //活动优惠活动商品列表
            Route::get('promotions/productList/:type', 'v2.activity.StorePromotions/productList');
			//优惠活动赠品信息
            Route::get('promotions/give_info/:id', 'v2.activity.StorePromotions/getPromotionsGive');
        });
        //需要授权
        Route::group(function () {
            Route::post('reset_cart', 'v2.order.StoreCart/resetCart')->name('resetCart');
            Route::get('new_coupon', 'v2.activity.StoreCoupons/getNewCoupon')->name('getNewCoupon');//获取新人券
            Route::post('user/user_update', 'v2.wechat.Routine/updateInfo');
            Route::post('order/product_coupon/:orderId', 'v2.activity.StoreCoupons/getOrderProductCoupon');//获取订单商品关联优惠券
            Route::get('user/service/record', 'v2.user.StoreService/record')->name('userServiceRecord');//客服聊天记录
            Route::get('cart_list', 'v2.order.StoreCart/getCartList');//门店首页购物车列表
			Route::get('cart/count', 'v2.order.StoreCart/count');//门店首页购物车数量
            Route::get('get_attr/:id/:type', 'v2.product.StoreProduct/getProductAttr');
            Route::post('set_cart_num', 'v2.order.StoreCart/setCartNum');
            //订单申请发票
            Route::post('order/make_up_invoice', 'v2.order.StoreOrderInvoice/makeUp')->name('orderMakeUpInvoice');
            //订单再次开票
            Route::post('order/make_once_invoice', 'v2.order.StoreOrderInvoice/onceMoreMakeUp')->name('orderonceMoreMakeUpInvoice');
            //用户发票列表
            Route::get('invoice', 'v2.user.UserInvoice/invoiceList')->name('userInvoiceLIst');
            //单个发票详情
            Route::get('invoice/detail/:id', 'v2.user.UserInvoice/invoice')->name('userInvoiceDetail');
            //修改|添加发票
            Route::post('invoice/save', 'v2.user.UserInvoice/saveInvoice')->name('userInvoiceSave');
            //设置默认发票
            Route::post('invoice/set_default/:id', 'v2.user.UserInvoice/setDefaultInvoice')->name('userInvoiceSetDefault');
            //获取默认发票
            Route::get('invoice/get_default/:type', 'v2.user.UserInvoice/getDefaultInvoice')->name('userInvoiceGetDefault');
            //删除发票
            Route::get('invoice/del/:id', 'v2.user.UserInvoice/delInvoice')->name('userInvoiceDel');
            //订单申请开票记录
            Route::get('order/invoice_list', 'v2.order.StoreOrderInvoice/list')->name('orderInvoiceList');
            //订单开票详情
            Route::get('order/invoice_detail/:uni', 'v2.order.StoreOrderInvoice/detail')->name('orderInvoiceList');

            //清除搜索记录
            Route::get('user/clean_search', 'v2.user.UserSearch/cleanUserSearch')->name('cleanUserSearch');
            //更新公众号用户信息
            Route::get('user/wechat', 'v2.user.User/updateUserInfo')->name('updateUserInfo');

            //参与抽奖
            Route::post('lottery', 'v2.activity.LuckLottery/luckLottery')->middleware(BlockerMiddleware::class)->name('luckLottery');
            //领取奖品
            Route::post('lottery/receive', 'v2.activity.LuckLottery/lotteryReceive')->middleware(BlockerMiddleware::class)->name('lotteryReceive');
            //抽奖记录
            Route::get('lottery/record', 'v2.activity.LuckLottery/lotteryRecord')->name('lotteryRecord');
            //获取分销等级列表
            Route::get('agent/level_list', 'v2.agent.AgentLevel/levelList')->name('agentLevelList');
            //获取分销等级任务列表
            Route::get('agent/level_task_list', 'v2.agent.AgentLevel/levelTaskList')->name('agentLevelTaskList');

            //获取用户余额、佣金、提现明细列表
            Route::get('user/money_list/:type', 'v2.user.User/userMoneyList')->name('userMoneyList');
            //获取用户推广用户列表
            Route::get('agent/agent_user_list/:type', 'v2.agent.Agent/agentUserList')->name('agentUserList');
            //获取用户推广获得收益，佣金轮播，分销规则
            Route::get('agent/agent_info', 'v2.agent.Agent/agentInfo')->name('agentInfo');
            //优惠活动凑单商品列表
            Route::get('promotions/collect_order/product', 'v2.activity.StorePromotions/collectOrderProduct');

            //拼单接口
            //验证是否在配送范围
            Route::get('is/within', 'v2.activity.UserCollage/isWithinScopeDistribution')->name('isWithinScopeDistribution');
            //发起拼单
            Route::get('user/initiate/collage', 'v2.activity.UserCollage/userInitiateCollage')->middleware(BlockerMiddleware::class)->name('userInitiateCollage');
            //检查用户是否发起拼单
            Route::get('is/user/initiate/collage', 'v2.activity.UserCollage/isUserInitiateCollage')->name('isUserInitiateCollage');
            //检查拼单
            Route::get('is/initiate/collage', 'v2.activity.UserCollage/isInitiateCollage')->name('isInitiateCollage');
            //购物车 统计 数量
            Route::get('user/initiate/collage/count', 'v2.activity.UserCollage/count')->name('count');
            //拼单购物车列表
            Route::get('user/initiate/collage/cart_list', 'v2.activity.UserCollage/getCartList')->name('getCartList');
            //拼单购物车删除商品
            Route::post('del/collage/cart', 'v2.activity.UserCollage/delUserCollagePartake')->name('delUserCollagePartake');
            //获取核销门店信息
            Route::get('collage/store/data', 'v2.activity.UserCollage/getStoredata')->name('getStoredata');
            //用户添加拼单商品
            Route::post('add/collage/partake', 'v2.activity.UserCollage/addCollagePartake')->name('addCollagePartake');
            //用户清空拼单数据
            Route::get('empty/collage/partake', 'v2.activity.UserCollage/emptyCollagePartake')->name('emptyCollagePartake');
            //复制他人拼单商品
            Route::get('duplicate/collage/partake', 'v2.activity.UserCollage/duplicateCollagePartake')->name('duplicateCollagePartake');
            //获取用户拼单数据
            Route::get('user/collage/partake', 'v2.activity.UserCollage/getUserCollagePartake')->name('getUserCollagePartake');
            //取消拼单
            Route::get('user/cancel', 'v2.activity.UserCollage/cancelInitiateCollage')->name('cancelInitiateCollage');
            //结算拼单
            Route::get('user/settle/collage', 'v2.activity.UserCollage/userSettleAccountsCollage')->name('userSettleAccountsCollage');

            //桌码
            //门店桌码配置
            Route::get('table/data', 'v2.activity.UserCode/getData')->name('getData');
            //记录桌码
            Route::get('add/table/code', 'v2.activity.UserCode/setTableCode')->name('setTableCode');
            //检查是否开启桌码
            Route::get('is/table/code', 'v2.activity.UserCode/isUserTableCode')->name('isUserTableCode');
            //处理换桌商品
            Route::get('changing/table', 'v2.activity.UserCode/userChangingTables')->name('userChangingTables');
            //获取桌码记录
            Route::get('get/table/code', 'v2.activity.UserCode/getTableCode')->name('getTableCode');
            //获取门店信息
            Route::get('get/store/data', 'v2.activity.UserCode/getStoredata')->name('getStoredata');
            //获取二维码信息
            Route::get('get/code/data', 'v2.activity.UserCode/getTableCodeData')->name('getTableCodeData');
            //桌码购物车 统计 数量
            Route::get('table/cart/count', 'v2.activity.UserCode/count')->name('count');
            //获取购物车
            Route::get('get/cate/list', 'v2.activity.UserCode/getCartList')->name('getCartList');
            //桌码购物车删除商品
            Route::post('del/table/cart', 'v2.activity.UserCode/delUserTableCodePartake')->name('delUserTableCodePartake');
            //确认下单
            Route::get('user/place/order', 'v2.activity.UserCode/userPlaceOrder')->name('userPlaceOrder');
            //用户添加桌码商品
            Route::get('add/table/cate', 'v2.activity.UserCode/addTableCodePartake')->name('addTableCodePartake');
            //用户清空购物车
            Route::get('user/empty/data', 'v2.activity.UserCode/emptyTablePartake')->name('emptyTablePartake');
            //获取桌码数据
            Route::get('get/table/partake', 'v2.activity.UserCode/getUserTableCodePartake')->name('getUserTableCodePartake');
            //结算拼单
            Route::get('user/settle/table', 'v2.activity.UserCode/userSettleAccountsCollage')->name('userSettleAccountsCollage');

        })->middleware(AuthTokenMiddleware::class, true);

        //授权不通过,不会抛出异常继续执行
        Route::group(function () {
            //用户搜索记录
            Route::get('user/search_list', 'v2.user.UserSearch/getUserSeachList')->name('userSearchList');
            Route::get('get_today_coupon', 'v2.activity.StoreCoupons/getTodayCoupon');//新优惠券弹窗接口
            Route::get('subscribe', 'v2.PublicController/subscribe')->name('WechatSubscribe');// 微信公众号用户是否关注
            //公共类
            Route::get('index', 'v2.PublicController/index')->name('index');//首页
            //优惠券
            Route::get('coupons', 'v2.activity.StoreCoupons/lst')->name('couponsList'); //可领取优惠券列表
            //商品评价列表
            Route::get('reply/list/:id', 'v2.product.StoreProduct/reply_list')->name('v2replyList');//商品评价列表

			//抽奖活动详情
			Route::get('lottery/info/[:factor]', 'v2.activity.LuckLottery/lotteryInfo')->name('lotteryInfo');

        })->middleware(AuthTokenMiddleware::class, false);

    })->middleware(StationOpenMiddleware::class);

	/**
	 * 营销路由
	 */
	Route::group('marketing', function () {

		//无需登录接口
		Route::group(function () {

		});

		//未授权接口---不会抛异常
		Route::group(function () {
			Route::get('short_video', 'v1.activity.Video/list')->name('shortVideoList');//短视频列表
            Route::get('short_video/info/:id', 'v1.activity.Video/info')->name('shortVideoProductInfo');//短视频详情
			Route::get('short_video/comment/:id', 'v1.activity.Video/commentList')->name('shortVideoCommentList');//短视频评论列表
			Route::get('short_video/product/:id', 'v1.activity.Video/productList')->name('shortVideoProductList');//短视频关联商品列表

			//新人礼
			Route::get('newcomer/product_list', 'v1.activity.StoreNewcomer/lst')->name('newcomerProductList');//新人专享商品
			Route::get('newcomer/product_detail/:id', 'v1.activity.StoreNewcomer/detail')->name('newcomerProductInfo');//新人商品详情

		})->middleware(AuthTokenMiddleware::class, false);

		//需要授权接口
		Route::group(function () {
			Route::post('short_video/comment/:id/:pid', 'v1.activity.Video/saveComment')->middleware(BlockerMiddleware::class)->name('shortVideoComment');//短视频评论
			Route::get('short_video/comment_reply/:pid', 'v1.activity.Video/commentReplyList')->name('shortVideoCommentReplyList');//短视频评论回复列表
			Route::delete('short_video/comment/:id', 'v1.activity.Video/commentDelete')->name('shortVideoCommentDelete');//删除短视频评论

			Route::get('short_video/comment/:type/:id', 'v1.activity.Video/commentRelation')->middleware(BlockerMiddleware::class)->name('shortVideoCommentRelation');//短视频评论点赞
			Route::get('short_video/:type/:id', 'v1.activity.Video/relation')->middleware(BlockerMiddleware::class)->name('shortVideoRelation');//短视频点赞、收藏、分享

			//新人礼
			Route::get('newcomer/info', 'v1.activity.StoreNewcomer/getInfo')->name('newcomerInfo');//新人礼信息
			Route::get('newcomer/gift', 'v1.activity.StoreNewcomer/getGift')->name('newcomerInfo');//新人大礼包弹窗信息

		})->middleware(AuthTokenMiddleware::class, true);

	})->middleware(StationOpenMiddleware::class);

	/**
	* pc 路由
	 */
    Route::group('pc', function () {
        //登陆接口
        Route::group(function () {
            Route::get('key', 'pc.Login/getLoginKey')->name('getLoginKey');//获取扫码登录key
            Route::get('scan/:key', 'pc.Login/scanLogin')->name('scanLogin');//检测扫码情况
            Route::get('get_appid', 'pc.Login/getAppid')->name('getAppid');//检测扫码情况
            Route::get('wechat_auth', 'pc.Login/wechatAuth')->name('wechatAuth');//检测扫码情况
        });

        //未授权接口
        Route::group(function () {
            Route::get('get_pay_vip_code', 'pc.Home/getPayVipCode')->name('getPayVipCode');//获取付费会员购买页面二维码
            Route::get('get_product_phone_buy', 'pc.Home/getProductPhoneBuy')->name('getProductPhoneBuy');//手机购买跳转url配置
            Route::get('get_banner', 'pc.Home/getBanner')->name('getBanner');//PC首页轮播图
            Route::get('get_category_product', 'pc.Home/getCategoryProduct')->name('getCategoryProduct');//首页分类尚品
            Route::get('get_products', 'pc.Product/getProductList')->name('getProductList');//商品列表
            Route::get('get_product_code/:product_id', 'pc.Product/getProductRoutineCode')->name('getProductRoutineCode');//商品详情小程序二维码
            Route::get('get_city/:pid', 'pc.PublicController/getCity')->name('getCity');//获取城市数据
            Route::get('check_order_status/:order_id/:end_time', 'pc.Order/checkOrderStatus')->name('checkOrderStatus');//轮询订单状态接口
            Route::get('get_company_info', 'pc.PublicController/getCompanyInfo')->name('getCompanyInfo');//获取公司信息
            Route::get('get_recommend/:type', 'pc.Product/getRecommendList')->name('getRecommendList');//获取推荐商品
            Route::get('get_wechat_qrcode', 'pc.PublicController/getWechatQrcode')->name('getWechatQrcode');//获取关注二维码
            Route::get('get_good_product', 'pc.Product/getGoodProduct')->name('getGoodProduct');//获取优品推荐
        })->middleware(AuthTokenMiddleware::class, false);

        //会员授权接口
        Route::group(function () {
            Route::get('get_cart_list', 'pc.Cart/getCartList')->name('getCartList');//购物车列表
            Route::get('get_balance_record/:type', 'pc.User/getBalanceRecord')->name('getBalanceRecord');//余额记录
            Route::get('get_order_list', 'pc.Order/getOrderList')->name('getOrderList');//订单列表
            Route::get('get_collect_list', 'pc.User/getCollectList')->name('getCollectList');//收藏列表
            Route::post('order/refund/cart_info', 'pc.Order/refundCartInfoList')->name('StoreOrderRefundCartInfoList');//获取退款商品列表
            Route::get('order/refund/list', 'pc.Order/refundList')->name('orderRefundList'); //售后订单列表
        })->middleware(AuthTokenMiddleware::class, true);

    })->middleware(StationOpenMiddleware::class);

	/**
	 * 移动端商家管理
	 */
	Route::group('admin', function () {
		//控制台
		Route::get('erp/config', 'admin.order.StoreOrder/getErpConfig')->name('getErpConfig');//获取erp配置
		Route::get('refund_order/list', 'admin.order.StoreOrder/refundOrderList')->name('RefundOrderList');//退款订单列表
		Route::get('refund_order/detail/:uni', 'admin.order.StoreOrder/refundOrderDetail')->name('RefundOrderDetail');//退款订单详情
		Route::post('refund_order/remark', 'admin.order.StoreOrder/refundRemark')->name('refundRemark');//退款订单备注

		//商品
		Route::group('product', function () {
			//代客下单商品
			Route::get('category', 'admin.product.StoreProductCategory/category')->name('category');//商品分类
			Route::get('list', 'admin.product.StoreProduct/lst')->name('products');//商品列表

			//商品管理
			Route::get('admin_list', 'admin.product.StoreProduct/adminList')->name('products');//管理商品列表
			Route::post('set_show', 'admin.product.StoreProduct/setShow')->name('setShow');//修改商品状态
			Route::get('product_label', 'admin.product.StoreProduct/labelTreeList')->name('labelTreeList');//商品标签树形列表
			Route::get('get_attr/:id', 'admin.product.StoreProduct/getAttr')->name('updateAttrs');//获取商品规格
			Route::post('update_attrs/:id', 'admin.product.StoreProduct/updateAttrs')->name('updateAttrs');//修改库存价格
			Route::post('batch_process', 'admin.product.StoreProduct/batchProcess')->name('batchProcess');//修改分类标签
		});


		//用户
		Route::group('user', function () {
			Route::get('list', 'admin.user.User/list')->name('list');//用户列表
			Route::get('label/:uid', 'admin.user.User/userLabel')->name('userLabel');//用户标签
			Route::get('coupon/grant', 'admin.user.User/couponGrant')->name('couponGrant');//优惠券列表
			Route::get('group/list', 'admin.user.User/userGroup')->name('userGroup');//用户分组
			Route::get('level/list', 'admin.user.User/userLevel')->name('userLevel');//用户等级
			Route::get('info/:uid', 'admin.user.User/info')->name('info');//用户详情
			Route::post('update_other/:uid', 'admin.user.User/updateOther')->middleware(BlockerMiddleware::class)->name('updateOther');//修改余额/积分
			Route::post('update', 'admin.user.User/update')->middleware(BlockerMiddleware::class)->name('update');//用户编辑

			Route::get('address/list/:uid', 'admin.user.UserAddress/address_list')->name('UserAddressList');//用户地址列表
			Route::get('address/default/:uid', 'admin.user.UserAddress/address_default')->name('addressDefault');//获取用户默认地址
		});

		//订单
		Route::group('order', function () {
			Route::get('statistics', 'admin.order.StoreOrder/statistics')->name('adminOrderStatistics');//订单数据统计
			Route::get('staging', 'admin.order.StoreOrder/stagingData')->name('adminOrderstagingData');//工作台数据统计
			Route::get('data', 'admin.order.StoreOrder/data')->name('adminOrderData');//订单每月统计数据
			Route::get('list', 'admin.order.StoreOrder/lst')->name('adminOrderList');//订单列表
			Route::get('detail/:orderId', 'admin.order.StoreOrder/detail')->name('adminOrderDetail');//订单详情
			Route::get('delivery/gain/:orderId', 'admin.order.StoreOrder/delivery_gain')->name('adminOrderDeliveryGain');//订单发货获取订单信息
			Route::post('delivery/keep/:id', 'admin.order.StoreOrder/delivery_keep')->middleware(BlockerMiddleware::class)->name('adminOrderDeliveryKeep');//订单发货
			Route::post('price', 'admin.order.StoreOrder/price')->name('adminOrderPrice');//订单改价
			Route::post('remark', 'admin.order.StoreOrder/remark')->name('adminOrderRemark');//订单备注
			Route::get('time', 'admin.order.StoreOrder/time')->name('adminOrderTime');//订单交易额
			Route::get('time/chart', 'admin.order.StoreOrder/timeChart')->name('timeChart');//订单交易额时间统计
			Route::post('offline', 'admin.order.StoreOrder/offline')->name('adminOrderOffline');//订单支付
			Route::post('refund', 'admin.order.StoreOrder/refund')->middleware(BlockerMiddleware::class)->name('adminOrderRefund');//订单退款
			Route::post('refund_agree/:id', 'admin.order.StoreOrder/agreeRefund')->name('adminOrderAgreeRefund');//商家同意退货退款

			Route::get('delivery/remind/:id', 'admin.order.StoreOrder/deliverRemind')->name('getDeliveryAll');//提醒发货
			Route::get('delivery', 'admin.order.StoreOrder/getDeliveryAll')->name('getDeliveryAll');//获取配送员
			Route::get('delivery_info', 'admin.order.StoreOrder/getDeliveryInfo')->name('getDeliveryInfo');//获取电子面单默认信息
			Route::get('export_temp', 'admin.order.StoreOrder/getExportTemp')->name('getExportTemp');//获取电子面单模板获取
			Route::get('export_all', 'admin.order.StoreOrder/getExportAll')->name('getExportAll');//获取物流公司
			Route::get('split_cart_info/:id', 'admin.order.StoreOrder/split_cart_info')->name('StoreOrderSplitCartInfo')->option(['real_name' => '获取订单可拆分商品列表']);//获取订单可拆分商品列表
			Route::put('split_delivery/:id', 'admin.order.StoreOrder/split_delivery')->middleware(BlockerMiddleware::class)->name('StoreOrderSplitDelivery')->option(['real_name' => '拆单发送货']);//拆单发送货
			Route::post('open/refund/:id', 'admin.order.StoreOrder/open_order_refund')->middleware(BlockerMiddleware::class)->name('openOrderRefund')->option(['real_name' => '拆单退款']);//拆单退款
			//订单核销
			Route::post('order_verific', 'admin.order.StoreOrder/order_verific')->middleware(BlockerMiddleware::class)->name('order');//订单核销
			Route::post('writeoff/records/:id', 'admin.order.StoreOrder/writeOffRecords')->middleware(BlockerMiddleware::class)->name('writeOffRecords')->option(['real_name' => '订单核销记录']);//订单核销记录

			//代客下单
			Route::get('cart/:uid', 'admin.order.StoreCart/getCartList')->name('orderCartList'); //购物车列表
			Route::post('cart/add/:uid', 'admin.order.StoreCart/addCart')->middleware(BlockerMiddleware::class)->name('cartAdd'); //购物车添加
			Route::delete('cart/del/:uid', 'admin.order.StoreCart/delCart')->name('cartDel'); //购物车删除
			Route::post('cart/num/:uid', 'admin.order.StoreCart/numCart')->name('cartNum'); //购物车 修改商品数量

			Route::get('place/list', 'admin.order.CreateOrder/lst')->name('orderPlaceList'); //代客下单记录
			Route::post('confirm/:uid', 'admin.order.CreateOrder/confirm')->name('orderConfirm'); //订单确认
			Route::post('computed/:key/:uid', 'admin.order.CreateOrder/computedOrder')->name('computedOrder'); //计算订单金额
			Route::get('coupons/:uid', 'admin.activity.StoreCoupons/order')->name('couponsOrder');//下单可使用优惠券
			Route::post('create/:key/:uid', 'admin.order.CreateOrder/createOrder')->middleware(BlockerMiddleware::class)->name('createOrder'); //代客下单：创建订单
			Route::post('pay/:uid', 'admin.order.CreateOrder/pay')->name('payOrder'); //代客下单支付信息
			Route::get('pay/status', 'admin.order.CreateOrder/checkOrderStatus')->option(['real_name' => '获取订单状态']);
            Route::post('check_shipping', 'admin.order.StoreOrder/checkShipping')->name('checkShipping'); //检测是否显示快递和核销标签
		});

	})->middleware(StationOpenMiddleware::class)->middleware(AuthTokenMiddleware::class, true)->middleware(\app\http\middleware\api\CustomerMiddleware::class);


	/**
	* 移动端门店中心 路由
	 */
	 Route::group('store', function () {
		//无需登录接口
		Route::group(function () {
			Route::get('category', 'v1.store.StoreProductCategory/category')->name('category');//商品分类
		});
		//未授权接口---不会抛异常
        Route::group(function () {
			Route::get('list', 'v1.store.Store/getStoreList')->name('storeList');//门店列表
			Route::get('customer/list/:store_id', 'v1.store.Store/getCustomerList')->name('customerList');//客服列表
			Route::get('customer/info/:id', 'v1.store.Store/getCustomerInfo')->name('customerInfo');//客服详情
			Route::get('products', 'v1.store.StoreProduct/lst')->name('storeProducts');//商品列表
        	Route::get('brand', 'v1.store.StoreProduct/brand')->name('brand');//品牌列表
        })->middleware(AuthTokenMiddleware::class, false);

		//需要授权
		Route::group(function () {
			Route::get('refund_order/list', 'store.order.RefundOrder/refundOrderList')->name('RefundOrderList');//退款订单列表
			Route::get('refund_order/detail/:uni', 'store.order.RefundOrder/refundOrderDetail')->name('RefundOrderDetail');//退款订单详情
			Route::post('refund_order/remark', 'store.order.RefundOrder/refundRemark')->name('refundRemark');//退款订单备注
			//门店店员
			Route::group('staff', function () {
				Route::get('info', 'store.StoreStaff/info')->name('storeStaffInfo');//门店店员信息
				Route::get('staging', 'store.StoreStaff/stagingData')->name('storeStagingData');//工作台数据统计
				Route::get('statistics', 'store.StoreStaff/statistics')->name('storeStatistics');//门店|店员统计信息
				Route::get('chart/:type', 'store.StoreStaff/timeChart')->name('timeChart');//统计曲线图
				Route::get('data/:type', 'store.StoreStaff/data');//店员统计信息列表
				Route::get('card/code', 'store.StoreStaff/code');//详细信息列表
			});
			//配送员
			Route::group('delivery', function () {
				Route::get('info', 'store.StoreDelivery/info')->name('storeStaffInfo');//配送员信息
				Route::get('statistics', 'store.StoreDelivery/statistics')->name('deliveryStatistics');//门店配送员统计信息
				Route::get('data', 'store.StoreDelivery/data')->name('deliveryData');//每月配送统计列表数据
				Route::get('order', 'store.StoreDelivery/orderList')->name('deliveryOrder');//配送员订单列表
				Route::get('list', 'store.StoreDelivery/getDeliveryAll')->name('getDeliveryAll');//获取配送员列表
				Route::get('orderList', 'store.StoreDelivery/orderListss')->name('orderList');//配送员订单列表
				Route::get('orderList_jilu', 'store.StoreDelivery/orderList_jilu')->name('orderList_jilu');//配送员订单记录
				Route::get('order_no_List', 'store.StoreDelivery/order_no_List')->name('order_no_List');//获取配送员列表
				Route::get('order_no_count', 'store.StoreDelivery/order_no_count')->name('order_no_count');//配送未结单订单合计
				Route::post('order_distribution', 'store.StoreDelivery/order_distribution')->name('order_distribution');//配送完成
				Route::post('is_peisongyuan', 'store.StoreDelivery/is_peisongyuan')->name('is_peisongyuan');//是否是配送员
				Route::post('select_work', 'store.StoreDelivery/select_work')->name('select_work');
				Route::post('worker_user_info', 'store.StoreDelivery/worker_user_info')->name('worker_user_info');//是否是配送员
				Route::post('get_user_info', 'store.StoreDelivery/get_user_info')->name('get_user_info');//获取配送员列表
				Route::post('add_user_comment', 'store.StoreDelivery/add_user_comment')->name('add_user_comment');//添加配送员评价
				//配货员----------------------------------------------------------------------------------------------------------
				Route::post('order_no_packing', 'store.StoreDelivery/order_no_packing')->name('order_no_packing');//配货员没有配货的订单列表
				Route::post('order_add_packing', 'store.StoreDelivery/order_add_packing')->name('order_add_packing');//配货员没有配货的订单列表
				Route::post('order_packing_ok', 'store.StoreDelivery/order_packing_ok')->name('order_packing_ok');//收银员没有收银的订单列表
                //水站配货员
                Route::post('order_no_packing1', 'store.StoreDelivery/order_no_packing1')->name('order_no_packing');//配货员没有配货的订单列表
                Route::post('order_add_packing1', 'store.StoreDelivery/order_add_packing1')->name('order_add_packing');//配货员没有配货的订单列表
                Route::post('order_packing_ok1', 'store.StoreDelivery/order_packing_ok1')->name('order_packing_ok');//配货员配货完成
                Route::post('order_no_shuizhan_packing_count', 'store.StoreDelivery/order_no_shuizhan_packing_count')->name('order_no_shuizhan_packing_count');//配货员没有配货数量
                Route::post('order_list_flow_count', 'store.StoreDelivery/order_list_flow_count')->name('order_list_flow_count');//配货员没有配货数量
                //==========================================
				Route::post('order_packing_jilu', 'store.StoreDelivery/order_packing_jilu')->name('order_packing_jilu');//收银员订单记录
				Route::post('order_list_flow', 'store.StoreDelivery/order_list_flow')->name('order_list_flow');//流转员订单
                ////水站流转员订单
                Route::post('order_list_flow1', 'store.StoreDelivery/order_list_flow1')->name('order_list_flow1');//水站流转员订单
                Route::post('order_list_flow_index1', 'store.StoreDelivery/order_list_flow_index1')->name('order_list_flow_index1');//流转员订单
                Route::post('order_ok_flow1', 'store.StoreDelivery/order_ok_flow1')->name('order_ok_flow1');//流转员流转完成处理逻辑
                Route::post('solve_status_refund1', 'store.StoreDelivery/solve_status_refund1')->name('solve_status_refund1');//流转员流转完成处理逻辑
                Route::post('refund_list', 'store.StoreDelivery/refund_list')->name('refund_list');//退货专区
                Route::post('refund_goods_num', 'store.StoreDelivery/refund_goods_num')->name('refund_goods_num');//退货商品入库

                Route::post('get_recovery_goods_list', 'store.StoreDelivery/get_recovery_goods_list')->name('get_recovery_goods_list');//退货记录




                Route::post('order_list_flow_index', 'store.StoreDelivery/order_list_flow_index')->name('order_list_flow_index');//流转员订单
				Route::post('order_ok_flow_list', 'store.StoreDelivery/order_ok_flow_list')->name('order_ok_flow_list');//流转员订单
				Route::post('order_flow_list_count', 'store.StoreDelivery/order_flow_list_count')->name('order_flow_list_count');//流转员订单count
				Route::post('flow_address', 'store.StoreDelivery/flow_address')->name('flow_address');//流转员站点列表
				Route::post('order_add_flow', 'store.StoreDelivery/order_add_flow')->name('order_add_flow');//流转员接单
				Route::post('delivery_building_save', 'store.StoreDelivery/delivery_building_save')->name('delivery_building_save');//流转员接单
				Route::post('delivery_building_list', 'store.StoreDelivery/delivery_building_list')->name('delivery_building_list');//流转员接单
				Route::post('delivery_user_list', 'store.StoreDelivery/delivery_user_list')->name('delivery_user_list');//流转员接单
				Route::post('order_ok_flow', 'store.StoreDelivery/order_ok_flows')->name('order_ok_flows');//流转员流转完成处理逻辑
				Route::post('solve_status_refund', 'store.StoreDelivery/solve_status_refund')->name('solve_status_refund');//售后处理
				Route::post('order_judge_correct', 'store.StoreDelivery/order_judge_correct')->name('order_judge_correct');//判断订单是否跟新

			});
			//商品
			Route::group('product', function () {
				//代客下单商品
				Route::get('category', 'store.product.StoreProductCategory/category')->name('category');//商品分类
				Route::get('list', 'store.product.StoreProduct/lst')->name('products');//商品列表
				//商品管理
				Route::get('admin_list', 'store.product.StoreProduct/adminList')->name('products');//管理商品列表
				Route::post('set_show', 'store.product.StoreProduct/setShow')->name('setShow');//修改商品状态
				Route::get('product_label', 'store.product.StoreProduct/labelTreeList')->name('labelTreeList');//商品标签树形列表
				Route::get('get_attr/:id', 'store.product.StoreProduct/getAttr')->name('updateAttrs');//获取商品规格
				Route::post('update_attrs/:id', 'store.product.StoreProduct/updateAttrs')->name('updateAttrs');//修改库存价格
				Route::post('batch_process', 'store.product.StoreProduct/batchProcess')->name('batchProcess');//修改分类标签
			});
			//用户
			Route::group('user', function () {
				Route::get('list', 'store.user.User/list')->name('list');//用户列表
				Route::get('label/:uid', 'store.user.User/userLabel')->name('userLabel');//用户标签
				Route::get('coupon/grant', 'store.user.User/couponGrant')->name('couponGrant');//优惠券列表
				Route::get('group/list', 'store.user.User/userGroup')->name('userGroup');//用户分组
				Route::get('level/list', 'store.user.User/userLevel')->name('userLevel');//用户等级
				Route::get('info/:uid', 'store.user.User/info')->name('info');//用户详情
				Route::get('address/list/:uid', 'store.user.UserAddress/address_list')->name('UserAddressList');//用户地址列表
				Route::get('address/default/:uid', 'store.user.UserAddress/address_default')->name('addressDefault');//获取用户默认地址
			});
			//订单
			Route::group('order', function () {
				Route::get('list', 'store.order.StoreOrder/lst')->name('adminOrderList');//订单列表
				Route::get('detail/:orderId', 'store.order.StoreOrder/detail')->name('adminOrderDetail');//订单详情
				Route::get('delivery/gain/:orderId', 'store.order.StoreOrder/delivery_gain')->name('adminOrderDeliveryGain');//订单发货获取订单信息
				Route::post('delivery/keep/:id', 'store.order.StoreOrder/delivery_keep')->name('adminOrderDeliveryKeep');//订单发货
				Route::post('price', 'store.order.StoreOrder/price')->name('adminOrderPrice');//订单改价
				Route::post('remark', 'store.order.StoreOrder/remark')->name('adminOrderRemark');//订单备注
				Route::get('time', 'store.order.StoreOrder/time')->name('adminOrderTime');//订单交易额
				Route::get('time/chart', 'store.order.StoreOrder/timeChart')->name('timeChart');//订单交易额时间统计
				Route::post('offline', 'store.order.StoreOrder/offline')->name('adminOrderOffline');//订单支付
				Route::post('refund', 'store.order.StoreOrder/refund')->middleware(BlockerMiddleware::class)->name('adminOrderRefund');//订单退款
				Route::post('refund_agree/:id', 'store.order.StoreOrder/agreeRefund')->name('adminOrderAgreeRefund');//商家同意退货退款

				Route::get('delivery/remind/:id', 'store.order.StoreOrder/deliverRemind')->name('getDeliveryAll');//获取配送员
				Route::get('delivery', 'store.StoreDelivery/getDeliveryAll')->name('getDeliveryAll');//获取配送员
				Route::get('delivery_info', 'store.order.StoreOrder/getDeliveryInfo')->name('getDeliveryInfo');//获取电子面单默认信息
				Route::get('export_temp', 'store.order.StoreOrder/getExportTemp')->name('getExportTemp');//获取电子面单模板获取
				Route::get('export_all', 'store.order.StoreOrder/getExportAll')->name('getExportAll');//获取物流公司
				Route::get('split_cart_info/:id', 'store.order.StoreOrder/split_cart_info')->name('StoreOrderSplitCartInfo')->option(['real_name' => '获取订单可拆分商品列表']);//获取订单可拆分商品列表
				Route::put('split_delivery/:id', 'store.order.StoreOrder/split_delivery')->middleware(BlockerMiddleware::class)->name('StoreOrderSplitDelivery')->option(['real_name' => '拆单发送货']);//拆单发送货
				Route::post('open/refund/:id', 'store.order.StoreOrder/open_order_refund')->middleware(BlockerMiddleware::class)->name('openOrderRefund')->option(['real_name' => '拆单退款']);//拆单退款

				//订单核销
				Route::get('writeoff_info/:type', 'store.order.StoreOrder/writeoffOrderinfo')->name('writeoffOrderinfo');//扫码核销获取订单信息
				Route::post('cart_info', 'store.order.StoreOrder/orderCartInfo')->name('writeoffOrderCartInfo');//核销获取商品信息
				Route::post('writeoff', 'store.order.StoreOrder/wirteoff')->middleware(BlockerMiddleware::class)->name('storeOrderWriteoff');//订单核销
				Route::post('order_verific', 'store.order.StoreOrder/order_verific')->middleware(BlockerMiddleware::class)->name('order');//订单核销
				Route::post('writeoff/records/:id', 'store.order.StoreOrder/writeOffRecords')->middleware(BlockerMiddleware::class)->name('writeOffRecords')->option(['real_name' => '订单核销记录']);//订单核销记录
			});

		})->middleware(AuthTokenMiddleware::class, true);

	 })->middleware(StationOpenMiddleware::class);

	/**
	 * 企业微信
	 */
	Route::group('work', function () {
		//获取企业微信jsSDK配置
		Route::get('config', 'v1.work.WorkController/config')->name('WorkConfig');
		//获取企业微信应用jsSDK配置
		Route::get('agentConfig', 'v1.work.WorkController/agentConfig')->name('agentConfig');
		//获取客户群详情
		Route::get('groupInfo', 'v1.work.GroupChat/getGroupInfo')->name('getGroupInfo');
		//获取群成员列表
		Route::get('groupMember/:id', 'v1.work.GroupChat/getChatMemberList')->name('getChatMemberList');

		Route::group(function () {
			//获取客户信息详情
			Route::get('client/info', 'v1.work.Client/getClientInfo')->name('getClientInfo');
			//获取客户订单列表
			Route::get('order/list', 'v1.work.Order/getUserOrderList')->name('getWorkOrderList');
			//获取客户订单详情
			Route::get('order/info/:id', 'v1.work.Order/orderInfo')->name('getWorkOrderInfo');
			//购买商品记录
			Route::get('product/cart_list', 'v1.work.Product/getCartProductList')->name('getCartProductList');
			//浏览记录商品记录
			Route::get('product/visit_list', 'v1.work.Product/getVisitProductList')->name('getVisitProductList');

		})->middleware(ClientMiddleware::class);
	});
	/**
	 *   室内快修
	 * api
	 */
	Route::group('order',function () {
		//无需登录接口
		Route::group(function () {
			Route::post('weixin_deploy', 'v1.repair.Order/weixin_deploy')->name('weixin_deploy');
			Route::get('get_two_cat', 'v1.repair.Order/get_two_cat')->name('get_two_cat');  //获取维修项目
			Route::get('get_two_cat_list', 'v1.repair.Order/get_two_cat_list')->name('get_two_cat_list');  //获取装修质保维修项目
			Route::get('get_two_category', 'v1.repair.Order/get_two_category')->name('get_two_category');  //获取第三方厂家
			Route::get('getRepairCatUserData', 'v1.repair.Order/getRepairCatUserData')->name('getRepairCatUserData');  //第三方厂商维修工列表

			Route::get('weixin_notice', 'v1.repair.Order/weixin_notice')->name('weixin_notice');  //用户须知
			Route::get('cs', 'v1.repair.Order/cs')->name('cs');  //测试位置距离
			Route::get('day3_ok', 'v1.repair.Order/day3_ok')->name('day3_ok');  //测试位置距离
			Route::get('wokr_type_cat', 'v1.repair.Order/wokr_type_cat')->name('wokr_type_cat');  //获取维修工种
			Route::get('examine_jvli', 'v1.repair.Order/examine_jvli')->name('examine_jvli');  //测试位置距离
		});
		Route::group(function () {
			Route::post('repair_create', 'v1.repair.Order/repair_create')->name('repair_create');  //创建维修单子
			Route::post('get_construction', 'v1.repair.Order/get_construction')->name('get_construction');  //查询装修质保类型是否申请中
			Route::post('announcement_list', 'v1.repair.Order/announcement_list')->name('announcement_list');  //创建维修单子
			Route::get('setAllRead', 'v1.repair.Order/setAllRead')->name('setAllRead');//获取用户和客服的消息列表

			Route::post('surveyor_info', 'v1.repair.Order/surveyor_info')->name('surveyor_info');  //查勘员信息
			Route::post('get_con_index', 'v1.repair.Order/get_con_index')->name('get_con_index');  //装修质保详情
			Route::post('get_violati_list', 'v1.repair.Order/get_violati_list')->name('get_violati_list');  //查勘员违规信息
			Route::post('get_violati_count', 'v1.repair.Order/get_violati_count')->name('get_violati_count');  //查勘员违规count

			Route::post('repair_info', 'v1.repair.Order/repair_info')->name('repair_info');  //维修工信息
			Route::post('worker_user_info', 'v1.repair.Order/worker_user_info')->name('worker_user_info');  //工人绩效
			Route::post('worker_user_list', 'v1.repair.Order/worker_user_list')->name('worker_user_list');  //工人绩效
			Route::post('get_work_list', 'v1.repair.Order/get_work_list')->name('get_work_list');  //打卡记录

			Route::post('add_work', 'v1.repair.Order/add_work')->name('add_work');  //上下班打卡
			Route::post('repair_assurance_create', 'v1.repair.Order/repair_assurance_create')->name('repair_create');  //创建质保订单
			Route::post('user_repair_list', 'v1.repair.Order/user_repair_list')->name('user_repair_list');  //正在维修订单列表
			Route::post('user_repair_list_ok', 'v1.repair.Order/user_repair_list_ok')->name('user_repair_list_ok');  //历史记录
			Route::post('user_repair_index', 'v1.repair.Order/user_repair_index')->name('user_repair_index');  //维修订单详情
			Route::post('maintenance_order', 'v1.repair.Order/maintenance_order')->name('maintenance_order');  //维修订单详情
			Route::post('user_repair_create', 'v1.repair.Order/user_repair_create')->name('user_repair_create');  //创建维修预约单子
			Route::post('user_repair_receive', 'v1.repair.Order/user_repair_receive')->name('user_repair_receive');  //维修接单
			Route::post('user_repair_call', 'v1.repair.Order/user_repair_call')->name('user_repair_call');  //上门
			Route::post('chaoshi', 'v1.repair.Order/chaoshi')->name('chaoshi');  //  超时
			Route::post('user_repair_ok', 'v1.repair.Order/user_repair_ok')->name('user_repair_ok');  //维修确认完成
			Route::post('add_maintenance_wenti', 'v1.repair.Order/add_maintenance_wenti')->name('add_maintenance_wenti');  //提交问题
			Route::post('maintenance_wenti_ok', 'v1.repair.Order/maintenance_wenti_ok')->name('maintenance_wenti_ok');  //完成
			Route::post('chargeback', 'v1.repair.Order/chargeback')->name('chargeback');  //退单
			//评价
			Route::post('repaircomment', 'v1.repair.Order/repaircomment')->name('repaircomment');
			Route::post('user_maintenance_list', 'v1.repair.Order/user_maintenance_list')->name('user_maintenance_list');  //维修工列表
			Route::post('user_maintenance_list_count', 'v1.repair.Order/user_maintenance_list_count')->name('user_maintenance_list_count');  //维修工列表

			Route::post('user_list_time', 'v1.repair.Order/user_list_time')->name('user_list_time');  //查询维修工预约时间
			Route::post('user_maintenance_list_ok', 'v1.repair.Order/user_maintenance_list_ok')->name('user_maintenance_list_ok');  //维修工列表
			Route::post('title_chuli', 'v1.repair.Order/title_chuli')->name('title_chuli');  //首页提示
			Route::post('cancel_order', 'v1.repair.Order/cancel_order')->name('cancel_order');  //取消订单


			Route::post('maintenance_wenti_assurance', 'v1.repair.Order/maintenance_wenti_assurance')->name('maintenance_wenti_assurance');
			Route::post('authority_list', 'v1.repair.Order/authority_list')->name('authority_list');  //查询维修工
			Route::post('maintenance_assurance_list', 'v1.repair.Order/maintenance_assurance_list')->name('maintenance_assurance_list');  //我的质保
			Route::post('user_count', 'v1.repair.Order/user_count')->name('user_count');  //正在快修的  和  历史记录
			Route::post('chaoshi2', 'v1.repair.Order/chaoshi2')->name('chaoshi2');  //超时
			Route::post('user_survey_call', 'v1.repair.Order/user_survey_call')->name('user_survey_call');  //勘察员上门打卡
			Route::post('decorate_assurance_list', 'v1.repair.Order/decorate_assurance_list')->name('decorate_assurance_list');  //勘察员上门打卡


			//111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111勘察院
			Route::post('list_surveyor', 'v1.repair.Order/list_surveyor')->name('list_surveyor');  //勘察员  订单列表
			Route::post('list_surveyor_count', 'v1.repair.Order/list_surveyor_count')->name('list_surveyor_count');  //勘察员  订单列表
			Route::post('get_survey_jilu', 'v1.repair.Order/get_survey_jilu')->name('get_survey_jilu');  //勘察员  接单记录列表
			Route::post('user_repair_surveyor', 'v1.repair.Order/user_repair_surveyor')->name('user_repair_surveyor');  //勘察员  接单
			Route::post('survey_user_add', 'v1.repair.Order/survey_user_add')->name('survey_user_add');  //勘察员转派给自己或者别人


		})->middleware(AuthTokenMiddleware::class, true);


	})->middleware(StationOpenMiddleware::class);
	//房源
	Route::group('housing',function () {
		//无需登录接口
		Route::group(function () {

		});
		Route::group(function () {
			//收藏列表
			Route::post('housing_collection_list', 'v1.housing.HousingCollection/housing_collection_list')->name('housing_collection_list');
			//收藏添加
			Route::post('housing_collection_add', 'v1.housing.HousingCollection/housing_collection_add')->name('housing_collection_add');
			//企业认证
			Route::post('enterprises_add', 'v1.housing.HousingEnterprisesAuthentication/enterprises_add')->name('enterprises_add');
			//企业判断
			Route::get('get_user_enterprises', 'v1.housing.HousingEnterprisesAuthentication/get_user_enterprises')->name('get_user_enterprises');
			//添加历史记录
			Route::post('historicalrecord_add', 'v1.housing.HousingHistoricalRecord/historicalrecord_add')->name('historicalrecord_add');
			//历史记录
			Route::post('historicalrecord_list', 'v1.housing.HousingHistoricalRecord/historicalrecord_list')->name('historicalrecord_list');
			//意见反馈
			Route::post('feedbacksuggestion_add', 'v1.housing.HousingFeedbackSuggestion/feedbacksuggestion_add')->name('feedbacksuggestion_add');
			//房产业态
			Route::post('HousingIndustry_list', 'v1.housing.HousingIndustry/HousingIndustry_list')->name('HousingIndustry_list');

			//房源标配
			Route::post('HousingLabel_list', 'v1.housing.HousingLabel/HousingLabel_list')->name('HousingLabel_list');
			//配套设施
			Route::post('HousingMatchingSetting_list', 'v1.housing.HousingMatchingSetting/HousingMatchingSetting_list');
			//城市地铁线列表
			Route::post('metrostation_list', 'v1.housing.HousingMetroStation/metrostation_list')->name('metrostation_list');
			//全国地铁城市
			Route::post('city_list', 'v1.housing.HousingMetroStation/city_list')->name('city_list');

			Route::post('housing_source_add', 'v1.housing.HousingSource/housing_source_add')->name('housing_source_add');  //添加房产
			Route::post('housing_source_index', 'v1.housing.HousingSource/housing_source_index')->name('housing_source_index');  //添加房产
			Route::post('user_housing_source_list', 'v1.housing.HousingSource/user_housing_source_list')->name('user_housing_source_list');  //用户下房产列表
			Route::post('housing_source_list', 'v1.housing.HousingSource/housing_source_list')->name('housing_source_list');

			Route::post('housing_source_isup', 'v1.housing.HousingSource/housing_source_isup')->name('housing_source_isup');  //上下架
			Route::post('housing_source_spread', 'v1.housing.HousingSource/housing_source_spread')->name('housing_source_spread');  //上架推广
			Route::post('housing_source_spread_discontinue', 'v1.housing.HousingSource/housing_source_spread_discontinue')->name('housing_source_spread_discontinue');  //下架推广
			Route::get('Integral_configure', 'v1.housing.HousingSource/Integral_configure')->name('Integral_configure');  //购买积分配置

			Route::post('housing_source_del', 'v1.housing.HousingSource/housing_source_del')->name('housing_source_del');  //删除
			Route::post('report_housing_add', 'v1.housing.HousingSource/report_housing_add')->name('report_housing_add');  //举报房源
			Route::post('create_intergral_order', 'v1.housing.HousingSource/create_intergral_order')->name('create_intergral_order');  //删除
			Route::post('an_appointment_add', 'v1.housing.AnAppointment/an_appointment_add')->name('an_appointment_add');  //预约添加
			Route::post('housing_like_list', 'v1.housing.HousingSource/housing_like_list')->name('housing_like_list'); 	//喜欢
			Route::post('an_appointment_list', 'v1.housing.AnAppointment/an_appointment_list')->name('an_appointment_list');//我的预约
			Route::post('appointment_del', 'v1.housing.AnAppointment/appointment_del')->name('appointment_del');//我的预约



		});

	})->middleware(AuthTokenMiddleware::class, true);



	/**
     * miss 路由
     */
    Route::miss(function () {
        if (app()->request->isOptions()) {
            $header = Config::get('cookie.header');
            $header['Access-Control-Allow-Origin'] = app()->request->header('origin');
            return Response::create('ok')->code(200)->header($header);
        } else
            return Response::create()->code(404);
    });

})->prefix('api.')->middleware(InstallMiddleware::class)->middleware(AllowOriginMiddleware::class)->middleware(StationOpenMiddleware::class);

